what's wrong with the following code : <template type T > T accumulate ( vector<T> in) { T total = in[0]; for (int i =0; i < in.length() ; i++) { total = total + in[i]; } return T }
Senior Interview Questions
340,828 senior interview questions shared by candidates
Rand(7) from Rand(5)
Write a function that divides one number by another, without using the division operator, and make it better than O(n).
How would I design the elevators for a new 40 story office building that had an average of 100 people per floor to most efficiently fill and empty the building given a standard 9-5 workday and traffic conditions in my city? The answer needed to be completely detailed, including expected passengers per car, time per stop, average floors stops per trip at various hours, etc.
They check for your attitude, your approach and your anxiety level! I solved both the case studies and I know I rocked the behavioral and Data challenge round, but still didn't ended up not being selected, why?
Describe a function to check if an integer is a power of 2.
Given an array like [-1, 2, 3, 5, 4, 6] and it should print the 3 that is order of the array is equal to array element
code a function that takes 2 parameters and an algorithm, print out all the numbers between the 2 parameters that completes the algorithm
Tell me about a time when you had to leave a task unfinished.
Another was a puzzle: A king orders 100 bottles of wine for a celebration. A courtier who's angry with the king over something puts poison in one of those bottles. The king has a way of identifying the poisoned bottle by giving a few drops of wine to a monkey. Since the poison is fast acting, the monkey will die immediately. Whats the minimum number of monkeys needed to find the poisoned bottle?
Viewing 51 - 60 interview questions