-What does the assignment X=(X)&(X-1) do? Use this to count number of 1s in a number.
Software Interview Questions
550,965 software interview questions shared by candidates
You have a 3 and a 5 gallon jug, how do you get exactly 4 gallons?
Accurately (this is the catch) read a 64bit register value using a method that can read only 32bit at a time
A IQ question: I have 9 coins and 8 have the same weight and the last one is heavier. I also have a balance beam to weigh the coins with. I can only use the balance beam 2 times to find the heavier coin. How do you find the heavier coin?
Technical Manager = What are you doing? How much are you willing to contribute? etc. This is mostly behaviour round. HR = Again, straight forward questions. Technical = this round contains two coding test. You will work as a team with some other candidate on a test. Basically, you have to demonstrate your teamwork skills. Also, how well you handle the situation e.g. are you a follower or a leader etc.
Given a sorted array of infinite length, how would you find a certain value?
Write algorithm to compute the intersection of two arrays. What is the time complexity of this algorithm (using the big O notation)?
1. What is a virtual? 2. If class has virtual function, what happens in compile time and in run time? 3. What is a polymorphism? 4. Write the function that gets array of chars and returns number of elements with 3 bits ON, performance is important. 5. Write the function that draws a line from x1,y1 to x2,y2 6. You have very long function with many return statements. You have to determine how much time it runs.
Design a Data Structure SpecialStack that supports all the stack operations like push(), pop(), isEmpty(), isFull() and an additional operation getMin() which should return minimum element from the SpecialStack. All these operations of SpecialStack must be O(1). To implement SpecialStack, you should only use standard Stack data structure and no other data structure like arrays, list, etc.
int getCount(int[] arr, int num)
Viewing 1611 - 1620 interview questions