Sort 0's, 1's in An Array. Sort 0's, 1's, 2's in An Array

You might also like

Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 1

Xome Interview Experience | Set 2 (On Campus- Software Developer)

Long Coding ( 2 hours)


 Designing a traffic mgmt system.
 You were assigned a person from the company who would aid you with any doubts and clarifications. He would also
regularly come and ask how far you have progressed. The emphasis was on the use of oops concepts, proper design of
classes, interfaces and abstraction. The solution needn’t be complicated. It could just be simple but meaningful.
Of the 32 students 9 were selected for the interviews. I was one among them.
Interview
1. Find the sum of all nodes greater than the given node’s value and store in the node in a BST?
(Note: this had to be done for all nodes in the BST)
2. Given two arrays find number that is present in array2 but not in array1.
3. Sort 0’s,1’s in an array.
4. Sort 0’s,1’s,2’s in an array.
5. 8 identical balls puzzle.
I did well but the reason I got rejected was that the guy who got selected had done the coding in notepad during long coding while I
had used Netbeans IDE. So that gave him an edge. Tough luck I guess.

Xome interview experience for software developer


Round-1:(1:15 min)
Basic questions on runtime polymorphism and static polymorphism
Multiple inheritance in java how can we implement using interfaces.
Connect all the nodes that are at the same level.
Implement stack such that middle element must be implement in constant time.

Round 2:(1 hr)


Your app uses a 3rd party video player. The VP has the functionalities – play, pause, seek, close. On close, the VP component makes
a callback to your app. It passes the below params on close –
a) total length of the video in seconds
b) array of VideoPart objects, where each VideoPart {startTime; endTime;}. VideoPart denotes continuous part of the video that was
watched withuot any disturbance due to pause or seek. Sequence of VP objects in the array, is the same sequence as he watched the
video parts.
60, [{0, 60}]
60, [{0, 30}, {30, 60}]
return a int value(0, 1) denoting the user has watched the entire video or not.
Round-3:(1:15min)
Removing duplicates in a given sorted array
Removing all nodes in a given bst.
Group reversal in a linked list.
Round-4(1:15min)
How can we sum at each level ..discussed on various of dfs and bfs approaches
Round-5(1:05min)
Given a binary tree..and node value.print the nearest leaf node for the node with given key.

You might also like