Software Engineer in Test Interview Questions
- 0of 0 votes
AnswersGiven two integer arrays which may contain duplicates, report the intersection of both the arrays.
- USC Trojon January 17, 2012 in United States| Report Duplicate | Flag | PURGE
Microsoft Software Engineer in Test - 0of 0 votes
AnswersGiven a doubly linked list containing only three integers 1,2,3. Sort the list without exchanging the values.
- Puzzle November 19, 2011 in India
Eg- 1->3->2->1->2->3->2->1->1
output: 1->1->1->1->2->2->2->3->3| Report Duplicate | Flag | PURGE
Amazon Software Engineer in Test Data Structures Linked Lists - 0of 0 votes
AnswersGiven a Binary tree where nodes may have positive or negative value, store the sum of the left and right subtree in the nodes.
Eg-10 -2 6 8 -4 7 5
Output:
- Puzzle November 19, 2011 in India20(-2+6+4+12) 4(8-4) 12(7+5) 0 0 0 0
| Report Duplicate | Flag | PURGE
Amazon Software Engineer in Test Trees and Graphs Data Structures - 0of 0 votes
AnswersGiven a number,find the next higher number using the same digits in the number. Eg- 15432, Soln- 21345.
- Puzzle November 19, 2011 in United States| Report Duplicate | Flag | PURGE
Amazon Software Engineer in Test Software Engineer / Developer Algorithm - 0of 0 votes
AnswersPlease tell the code of how to sort a singly linkedlist in C# or C++.
- Gary November 18, 2011 in United States| Report Duplicate | Flag | PURGE
Software Engineer in Test - 0of 0 votes
AnswersThere is a very Primitive Database and it has a table say "Travel". The content of table is as follows:
- Mi Jalgaonkar November 15, 2011 in United States
Source | Dest
--------------
Sea | LA
LA | FL
LA | MA
FL | Sea
Sea | FL
The ask is to find out all routes between (Sea) to (FL) with mininum hop.
the Result would be:
1. Sea -> FL
2. Sea -> LA - > FL
You have to write a Middle tier function to achieve above result. You can assume there is DBAPI that return the Destination city if you provide the source city.| Report Duplicate | Flag | PURGE
Microsoft Software Engineer in Test - 0of 0 votes
AnswersGiven a tree, parse the tree using breadth first search and then find the last element in the tree. After finding the last element, replace that element with the root node. Eg. Input:
A B C D E F G
Output:
- naphstor October 29, 2011 in United StatesG B C D E F A
| Report Duplicate | Flag | PURGE
Microsoft Software Engineer in Test Data Structures - 0of 0 votes
AnswersGiven a binary search tree. Find the maximum depth of the binary search tree iteratively.
- cinderella October 29, 2011 in United States for Windows Live| Report Duplicate | Flag | PURGE
Microsoft Software Engineer in Test - 0of 0 votes
AnswersHow much memory will be allocated from the "stack" for the following declarations together?
- devanharikumar89 October 20, 2011 in India
int *a;
char *b;
This was an objective question. a and b have not been malloced yet.| Report Duplicate | Flag | PURGE
Microsoft Software Engineer in Test - 0of 0 votes
AnswersA new USB memory device is designed with the following functionalities.
- devanharikumar89 October 19, 2011 in India
1. when connected to a camera, it opens the data transfer wizard.
2. When connected to another storage device, it copies data.
3. When connected to a smart phone, it sync's. the contacts
<there were a couple of others too.>
Write the test cases.| Report Duplicate | Flag | PURGE
Microsoft Software Engineer in Test - 0of 0 votes
Answerswrite a function to reverse a linked list in the following fashion.
- devanharikumar89 October 19, 2011 in India
given: a list : a b c d e f
a number N
output should be: if N=2
b a d c f e
if N=3
c b a f e d
ie, the list should be reversed in <N><N>...<N> intervals. We are not allowed to allocate any new nodes.| Report Duplicate | Flag | PURGE
Microsoft Software Engineer in Test - 0of 0 votes
Answersfind the number of solutions (non-negative integral) for the equation x1+x2+x3+x4+x5=20.
- devanharikumar89 October 19, 2011 in India
ie, #((0,0,0,0,20),(0,0,0,20,0),....)| Report Duplicate | Flag | PURGE
Microsoft Software Engineer in Test - 0of 0 votes
AnswersGiven a linked list with each node having two pointers: A next pointer pointing to the next node and a random pointer pointing to a random node in the link list. The random pointer can also point to null.
- vinaysachdeva23 October 13, 2011 in India
Struct Node
{
int val;
Struct Node* next;
Struct Node* random;
}
Write a function Node* CloneList(Node* head) to clone the list.| Report Duplicate | Flag | PURGE
Amazon Software Engineer in Test - 11of 15 votes
AnswersGiven an int array which might contain duplicates, find the largest subset of it which form a sequence.
- learner October 06, 2011 in -
Eg. {1,6,10,4,7,9,5}
then ans is 4,5,6,7
Sorting is an obvious solution. Can this be done in O(n) time| Report Duplicate | Flag | PURGE
Google Software Engineer in Test Software Engineer / Developer Arrays Algorithm - 0of 0 votes
AnswersPartition an int array in 2 equal parts such that the avg of two is equal.
- learner October 06, 2011 in India
Provide algo only, dont write code| Report Duplicate | Flag | PURGE
Google Software Engineer in Test - 0of 0 votes
AnswersHow can you merge two BST inplace so that preserving the BST property?
- learner October 06, 2011 in India
Provide algo only, dont write code| Report Duplicate | Flag | PURGE
Google Software Engineer in Test Trees and Graphs - 0of 0 votes
AnswersHow to find the outside temperature when you are in a room ? There is no thermometer or TV or any other person or sensor which can tell you anything.Although there is a window in a room.
- jollywagoner September 21, 2011 for SQL Server| Report Duplicate | Flag | PURGE
Software Engineer in Test - 0of 0 votes
Answerstwo 32bit integers m,n are given.replace all the bits in m from i to j locations with all the bits in n from k to l locations....
- laasya1991 September 13, 2011 in India
eg.m=110000000000 n=10101010 i=3 j=5 k=5 l=7
o/p:110000101000
some one give me the solution| Report Duplicate | Flag | PURGE
Microsoft Software Engineer in Test - 0of 0 votes
Answersdevelop a solution for an elevator system in a building having 50 floors.. the main criteria is that the lift should be available all the time
- laasya1991 September 13, 2011 in India| Report Duplicate | Flag | PURGE
Microsoft Software Engineer in Test - 0of 0 votes
Answersreplace all the spaces in a string with %20
- laasya1991 September 13, 2011 in India| Report Duplicate | Flag | PURGE
Microsoft Software Engineer in Test - 0of 0 votes
Answerstest cases for mobile phone
- laasya1991 September 13, 2011 in India| Report Duplicate | Flag | PURGE
Microsoft Software Engineer in Test - 0of 0 votes
AnswersDesign a class for a product, which has several promotional offers based on its buy weight. Input are: product-Rice,buy weight-105kg, provided the offer price are Rs.30/Kg, Rs.28 per 2Kg, Rs.25 per 5Kg, Rs.24 per 10Kg. Come out with an output that would quote the least price, and if there are 2 offers with the same price, the choice has to be made on the least number of baggages.
- sayantanroy86 September 08, 2011 in India| Report Duplicate | Flag | PURGE
Amazon Software Engineer in Test Algorithm - 0of 0 votes
AnswersGiven an n-ary tree of resources arranged hierarchically. A process needs to lock a resource node in order to use it. But a node cannot be locked if any of its descendant or ancestor is locked. You are supposed to:
- nr September 07, 2011 in United States
-> write the structure of node
-> write codes for
Islock()- returns true if a given node is locked and false if it is not
Lock()- locks the given node if possible and updates lock information
Unlock()- unlocks the node and updates information.
Codes should be :
Islock –O(1)
Lock()- O(log n)
unLock()- O(log n)| Report Duplicate | Flag | PURGE
Amazon Software Engineer in Test Algorithm - 0of 0 votes
AnswersGiven a stream of text eg you can read 1 char at a time, write fn that will return true if you can find a string str in the stream before the stream runs out
- supercooldude100 September 05, 2011
What if the string you are looking for is abc
And the stream is aaabababcab
I gave a solution using a stringbuilder ( like a circular array) but he didn’t like it. He wanted a solution that doesn’t require space equal to the string you are looking for| Report Duplicate | Flag | PURGE
Microsoft Software Engineer in Test Algorithm - 0of 0 votes
AnswersWrite a function to check if the two strings given are anagrams are not. here AAbCDE and DECbAA are anagrams.Also, ABC and BCA are anagrams. however, AABBC and CBBAA are not anagrams.
- djroxx August 20, 2011| Report Duplicate | Flag | PURGE
Amazon Software Engineer in Test Coding