## Recent Interview Questions

More Questions »- 1of 1 vote
Lets say someone accidentally deleted all the whitespaces from a sentence. Write a program to reconstruct the sentence from that stripped out string. Assume you have access to a dictionary function that returns if a given string is a valid word or not.

Example input: thisisavalidsentence

Output: this is a valid sentence

If multiple solutions are possible, any one valid solution should be given. Assume there is always a valid solution. No invalid input will be given.

- 0of 0 votes
Given a BST and a number n, find two numbers in the tree that sums up to n. This was to be done in place i.e. without any extra space.

- 0of 0 votes
Return the sum of all the leaf nodes at minimum level in a binary tree. If there exists no tree, then return -1.

- 0of 0 votes
given a sorted array in ascending order arrange the elements of array in such a way that largest element is at first position and second largest element at last position third largest at second position and fourth largest at last second position and so on.try to do it without any extra space.

- 0of 0 votes
Ideal goal:

Given data set of strings divide them into equivalence classes such that the equivalence relation is fuzzyMatchingOfString

Problem: as far as I know there isn’t a relation function fuzzyMatchingOfString such that it is transitive, i.e. given A,B,C and fuzzyMatchingOfString(A,B), fuzzyMatchingOfString(B,C) does not imply fuzzyMatchingOfString(A,C)

e.g. foo ~ goo and goo~gol but not foo~gol

given that I think we have to compromise about our goal and create a set to each string In our data set – that is n^2 for each run when the basic action is fuzzyMatchingOfString