Interview 1
Interview 2
Interview 3
val). You need to print out all possible paths in the BST which sum to val. These paths may or may not start at the root.a and b. You need to convert string a to b such that only one alphabet is changed at a time, and after each change, the transformed string is in the dictionary. You need to do this in the minimum number of transformations. For example, the transformation from cat to boy can be done as follows:
cat → bat → bot → boy (if the dictionary contains bat and bot).Interview 4
You have been given a tree (not binary; it can have any number of children) in an array. The ith entry of the array is the parent of the ith node. For the root node, this entry is -1. You need to find the height of this tree (an O(N) solution was asked for). For example, the array [2,6,3,6,3,6,-1] represents the tree below. The height of the tree is 4 (the path from 6 to 0).
6
/ | \
1 3 5
/ \
2 4
/
0
You are given an array of numbers. Your task is to print the length of the maximum continuous sequence that you encounter.
For example, if the 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.
An O(n) solution was requested, assuming you have a hash map that supports O(1) insertion and fetching operations.
The following metrics were computed from 5 interview experiences for the Microsoft Software Development Engineer II role in Bengaluru, Karnataka.
Microsoft's interview process for their Software Development Engineer II roles in Bengaluru, Karnataka is on the easier side as most engineers get an offer after going through it.
Candidates reported having very good feelings for Microsoft's Software Development Engineer II interview process in Bengaluru, Karnataka.