Write a function that determines whether a given number is a prime. Discuss perf improvements.
Development Interview Questions
137,277 development interview questions shared by candidates
Describe a data structure for which getValue(int index), setValue(int index, int value), and setAllValues(int value) are all O(1).
N people are sitting in a circle labelled 1 through n. They being counting 1,2,3,.... in a clockwise manner and every person that gets a number divisible by 3 is eliminated. Write a program to figure out which numbered person will remain. What's the time and space complexity?
Implement the fibonacci sequence
Reverse the individual words in a string (words are delimited by spaces). Example - "Hello world" becomes "olleH dlrow".
Diagonally flip a two dimensional array.
Given the root of a binary search tree, link all the nodes at the same level, by using an additional Node* level.
How can you write a recursive function calculating the exponential of a number?
Reserve link listed pair-wise
Phone interview question: What happens when the "new" operator in C++ fails?
Viewing 1091 - 1100 interview questions