Hi,
Written Test
There were 40 questions (20 each of math’s and analytical ability) to solved in 60 minutes. Marking scheme was +2.5 for correct answer and -1 for wrong answer. They were easy just remember don’t get struck at any point and do not do guess work. The cut-off is usually around 60%. This round is the most important one as it is the main elimination round.
Coding Round
There were 4 questions to be coded in any language in 90 minutes.
Quest 1. You are given a n*n matrix. You can go upward, downward, left or right. No diagonal moves are allowed. You are given a starting location and the destination. Also given is the cost of going in each cell.
You have to write a function which prints the path to the destination from the source which has minimum cost and returns the minimum costs.
For example:
Given a 3*3 matrix
Find the shortest path between (0,0) to (2,2)
| 2 | 5 | 6 |
| 4 | 8 | 4 |
| 2 | 1 | 3 |
Here the path with minimum cost is
(0,0) -> (1,0) -> (2,0) -> (2,1) -> (2,2)
Quest 2. You are given two integers. You have to write a function to add their reversed equivalent (i.e. the number with its digits reversed for ex 24 becomes 42) and return the reverse of the sum. Assume the reverse of 12 is 21 and not 210 or 2100
The prototype is: int AddReverse(int num1,int num2)
For example
Input : 24 35
Output : 59
Input: 227 872
Output: 1 ( And not 0001)
Input: 30 23
Output: 53 ( 3 + 32 = 35 so output 53)
Quest 3. You are given a array of words. You are also given a character array which contains all the unique characters present in the first array sorted in a special order. Assume all characters are in lowercase. You have to sort the first array according to the order specified in the second array.
For example
Arr1[][] = { “cd”, “ef”, “pq”, “cg”}
Arr2[] = { ‘p’, ‘e’, ‘c’ , ‘g’, ‘d’ , ‘f’ , ‘q’}
Sorted array is
“pq” , “ef” , “cg” , “cd”
Quest 4. You are given a string. You have to find the longest increasing subsequence of the string.
For example
Input: “abcablogsd”
Output: “ablo”
HR Round
1. About Myself.
2. What all project I have done.
3. What all technologies I have done.
4. How many seniors I know working in nagarro. Do I keep in touch with them.
5. Why i want to join nagarro.
6. How many years I plan to stay in nagarro.
7. Rate myself in coding skills in my class.
8. About My family.
9. About my marks.
10. About night shifts.
11. Where do I put up and how will I manage transportation to Gurgaon.
12. They asked me question about placement policy and which all companies have visted. How many offers a student can get. Am I already placed.( I declined to answer any of those saying I am not permitted to say anything about it)
13. Will I be able to learn new technologies and will I be able to switch to different domain.
Technical Round
1. About Myself.
2. Then he asked me to explain the codes I have written in the coding round.
He was interested in the logic I used and saw the syntax how I write the code. And asked at some point why u have written this particular line of code? What this particular line will do? Where have u implemented this portion of the logic?
3. In the third question he asked if any optimization are possible.
4. Since I was able to code only three questions in the required time limit, He asked me why I was not able to code the fourth question. ( I said My writing speed is slow and I knew the logic but due to time constraints I was not able to code it.) He said as u have written codes in other question you didn’t needed to write there psedo codes and logic and assumptions, by which I cud have gained more time to write the code.
5. He asked me to print
12345
23451
34512
45123
51234
In one for loop. He gave me just a minute to write it.
6. He asked me to implement a random function with a seed. And to implement it quickly.( He said don’t use any physical and biological properties) and to implement it very quickly.
Well that’s it from my side. I was selected wish u will get selected too.
ALL THE BEST
No comments:
Post a Comment