design a ADT to implement push(), pop() method as stack, and also has a getMinElement(). Require that getMinElement() is constant time but push()/pop() do not have to be constant time at first. Then for improvement, these three methods are all required to be constant time
Software Development Interview Questions
36,966 software development interview questions shared by candidates
1) Given a array and a sum, find all the pairs in the array which have the given sum. 2) Given a BST you need to identify swapped nodes
Given two binary trees T1 and T2. Find if T2 is a sub-tree of T1.
Make a program that writes a Binary Search Tree to a file. Now create a program that reads those files and recreates a Binary Search Tree.
You are given an array of numbers. You need to print the length of the maximum continuous sequence that you encounter. For example if input is [3,8,10,1,9,6,5,7,2 ], the continuous sequences are{1,2,3} and {5,6,7,8,9,10} the latter is the longest one so the answer becomes 6. O(n) solution was asked for, assuming you have a hash map which supports O(1) insertion and fetching operations
Signed an NDA, so I will not post the questions.
I signed NDA for online assessments. For the phone interview, questions about DS and string manipulation. Should be good if can solve medium level HackerRank or Leetcode problems.
i) Given a value v, in a BST find the next value in order.
Find k largest/smallest number in a series of numbers. What data-structures will you use? Code it on white board.
Given a set of N numbers, assume that you have the set of numbers from 1 to N+1, with the exception of one number. How do you determine what number that is? What is the complexity of your solution?
Viewing 71 - 80 interview questions