Flipkart conducted its test on Interviewstreet. There were 20 objective questions and 2 programming questions. Test was for 2 hours.
Here are the 2 programming questions :
1) You are given an array of integers. You need to find the minimum number of swaps necessary to make the array sorted.
Eg. [3,2,1] -> 3 swaps needed
[1,2,3] -> 0 swaps needed
2) Snakes and ladders game. Find the smallest number of jumps (ie optimal no of dice throws) needed to win a snakes and ladders game. Assume you are given a board with all the necessary inputs like start/end positions of all ladders and snakes. (Hint: Think about the problem in terms of a graph)
Here are the 2 programming questions :
1) You are given an array of integers. You need to find the minimum number of swaps necessary to make the array sorted.
Eg. [3,2,1] -> 3 swaps needed
[1,2,3] -> 0 swaps needed
2) Snakes and ladders game. Find the smallest number of jumps (ie optimal no of dice throws) needed to win a snakes and ladders game. Assume you are given a board with all the necessary inputs like start/end positions of all ladders and snakes. (Hint: Think about the problem in terms of a graph)