BloombergLP Financial Software Developer Interview

BloombergLP Financial Software Developer Interview
1)How would you find a number in a dataset of unknown size?
2)How would you write a spellcheck program that would highlight misspelled words as you typed?
3)What is a dangling reference? Give sample code?
4)How do you avoid dangling pointers and dangling references? Can you have a const reference to an object i.e. MyClass& const refToObj;? Does having a const* to an object guarantee safety from seg faults? What is the best alternative?
5)What happens when you get a segmentation fault? how do you get it and how is it implemented?
6)Lets say there is a lottery. You get 6 numbers and in order to win, the sum of the first 3 numbers have to equal the sum of the second 3. How many possible chances are there to win?
7)There are 9 stones on the table, one is little heavier that other 8. Using a medical scales, how would you find the heavier one with exactly 2 measurements?
8)Find the most populous character in a string? Most optimal solution is desired?
9)How you detect a cycle in a graph?

No comments: