Software Engineer in Test Interview Questions
- 0of 0 votes
AnswersFind Bugs in the following function-
- ISL January 29, 2011
This function accepts a string and its length and it supposed to return number of A or a present in that string-
unsigned int occur(char *pch,unsigned long len)
{
int tmpvar=len;
int i=0;
int ret=0;
if(*pch==NULL || !strcmp(pch," "))
return 0;
do
{
if(pch[i]=='A' || pch[i]=='a')
ret++;
else
i++;
}while(i<tmpvar);
return ret;
}| Report Duplicate | Flag | PURGE
Microsoft Software Engineer in Test - 0of 0 votes
AnswersGiven 2 strings S1 and S2, Check the first charaster that is repeated in S2.
- Anonymous January 17, 2011| Report Duplicate | Flag | PURGE
Microsoft Software Engineer in Test - 0of 0 votes
AnswersGiven array of n integers and given a number X, find all the unique pairs of elemens (a,b), whoose some is equal to X.
- Anonymous January 17, 2011| Report Duplicate | Flag | PURGE
Microsoft Software Engineer in Test Algorithm - 0of 0 votes
Answerswrite down String class copy constructor ?
- siva.sai.2020 December 28, 2010| Report Duplicate | Flag | PURGE
Microsoft Software Engineer in Test - 0of 0 votes
Answersfind a bug in following code : class A { public: static int i; void print() { cout<< i << endl ; } }; int main() { A a; a.print(); }
I run above code, and I am getting "ndefined reference to `A::i'" . Why I am getting this error ?
- siva.sai.2020 December 28, 2010| Report Duplicate | Flag | PURGE
Microsoft Software Engineer in Test - 0of 0 votes
AnswersRound-I Write a function that takes an array of five integers, each of which is between 1 and 10, and returns the number of combinations of those integers that sum to 15. For example, calling the function with the array [1, 2, 3, 4, 5] should return 1, while calling it with [5, 5, 10, 2, 3] should return 4 (5 + 10, 5 + 10, 5 + 5 + 2 + 3, 10 + 2 + 3). You may assume that the input has already been validated.
- Tim December 25, 2010| Report Duplicate | Flag | PURGE
Amazon Software Engineer in Test Algorithm - 0of 0 votes
AnswersHow will you rotate a given matrix? Question from CC book.
- Tim December 25, 2010| Report Duplicate | Flag | PURGE
Amazon Software Engineer in Test Algorithm - 0of 0 votes
AnswersIf given a position (x,y) of knight on a chess board, how will you determine all the valid moves that a knight can move. I coded the function on the while board by using a helper function IsValidMove(x,y)
- Tim December 25, 2010| Report Duplicate | Flag | PURGE
Amazon Software Engineer in Test Algorithm - 0of 0 votes
AnswersHow to compare two version numbers?
- Muskaan December 18, 2010
E.G. 1.2.30.112 @ 2.12.11.09
Code should be in java| Report Duplicate | Flag | PURGE
Intuit Software Engineer in Test - 0of 0 votes
AnswerHow to write a stub for unavailable server?
- ss December 15, 2010| Report Duplicate | Flag | PURGE
Software Engineer in Test - 0of 0 votes
AnswersA application uses different its own server and some external, third party server also. Suppose if external or third party server is unavaiable, how will you test application?
- muskaan December 15, 2010
What will be the approach to test the application when you are not getting third party server?| Report Duplicate | Flag | PURGE
Apple Software Engineer in Test Testing - 0of 0 votes
AnswersWhen would a teleportation device not increase the speed of your commute?
- sat December 15, 2010| Report Duplicate | Flag | PURGE
Microsoft Software Engineer in Test Brain Teasers - 0of 0 votes
AnswersHow would you test a Elevator?
- Anonymous December 14, 2010| Report Duplicate | Flag | PURGE
Microsoft Software Engineer in Test Testing - 0of 0 votes
AnswersExplain one of your project you have done in your past and what challenges did you face in that? If given one chance what would you like to change in the project you worked on
- Anonymous December 14, 2010| Report Duplicate | Flag | PURGE
Microsoft Software Engineer in Test Java - 0of 0 votes
AnswersWhy Microsoft? Why did you choose this major for Masters. what are good coding practice? How do you grade yourself as a coder/programmer.
- Anonymous December 14, 2010| Report Duplicate | Flag | PURGE
Microsoft Software Engineer in Test Behavioral - 0of 0 votes
AnswersWrite a function to convert Hex to Dec
- Anonymous December 09, 2010
int ConvertHexToDec(string)| Report Duplicate | Flag | PURGE
Software Engineer in Test C# - 0of 0 votes
Answersinterview:
- Anonymous December 05, 2010
Implement run length encoding and decoding.
Input:
aabbccaa encode:2a2b2c2a decode will be the input
Input: abcd encode:abcd decode:abcd
input:3122a encode:3122a decode:3122a
etc.| Report Duplicate | Flag | PURGE
Microsoft Software Engineer in Test - 0of 0 votes
Answerstest atof(char *s)
- Anonymous December 05, 2010| Report Duplicate | Flag | PURGE
Microsoft Software Engineer in Test - 0of 0 votes
Answerswritten test:
- Anonymous December 05, 2010
print all the leaves of a binary tree(may not complete) as a link list.
1
/\
2 3
/\
4 5
output as a list: 4->5->3->NULL| Report Duplicate | Flag | PURGE
Microsoft Software Engineer in Test - 0of 0 votes
AnswersHow do you test a function which would return the second smallest number in a BST?
- Guest December 04, 2010| Report Duplicate | Flag | PURGE
Microsoft Software Engineer in Test Testing - 0of 0 votes
AnswersBangalore written test
- Anonymous December 04, 2010
fucntion prints given 2d array in spiral fashion. give all test cases to test it| Report Duplicate | Flag | PURGE
Microsoft Software Engineer in Test Coding - 0of 0 votes
AnswersString s1 = bacdeg
- Anonymous December 04, 2010
String s2 = bcdaeg
write an algorithm which will return position of first character of string s1 that is appearing in s2
here postion of 'a' in string s2 as it is the first character of s1 that is coming in s2| Report Duplicate | Flag | PURGE
Microsoft Software Engineer in Test Algorithm - 0of 0 votes
AnswersBangalore written test
- Anonymous December 04, 2010
C function was given to find out the occurance of character "A" from an array. Need to find out the bugs in program.| Report Duplicate | Flag | PURGE
Microsoft Software Engineer in Test Coding - 0of 0 votes
AnswersQuestion asked in microsoft written test :
- Anonymous November 22, 2010
Write a function which finds a substring in a string and replaces all such occurances with another string. Prototype of the function :
char* FindReplace(char* src, char* find, char* replace);| Report Duplicate | Flag | PURGE
Microsoft Software Engineer in Test C - 0of 0 votes
AnswersGiven an array containing lower case and upper case alphabets and numbers, how can you sort/arrange the array in one single pass using just one variable for swapping such that the resultant array should put the input elements into 3 buckets in the following fashion -
- YT2010 November 18, 2010
Input - aA1B23Cbc4
Output - abcABC1234
Note - ordering doesn't matter
the output could be -
ABC1234abc or 1234abcABC
You just have to arrange the data into 3 buckets in single pass using just one temp variable for swapping. Expected runtime - o(n)| Report Duplicate | Flag | PURGE
Microsoft Software Engineer in Test Arrays