Nagarro Placement-Paper

Hello
Nagarro visited our campus(Bharati Vidyapeeth, Paschim Vihar) for placements. They conduct 2 rounds on the first day.

1. Aptitude Test – 60min
20 questions of maths(trigo, mensuration, ratios, percentage, mean etc)
20 questions of analytical/logical ability
The cut off for this round is 60%. Negative marking is there.

2. Coding Test – 75min
It consists of 3 questions which can be attempted in any language you want or you may write pseudo-code if you dont remember syntax of any language. The
code should be as efficient as possible. The questions were:-

Ques1 : Given two file paths inputFilePath and outputFilePath, write a function void Remove Comments(char inputFilePath[], char outputFilePath[]) suchthat the contents of file referred by inputFilePath are copied to the file
given by outputFilePath after removing the comments. In other words, first file contains a C program which should be copied to the second file excluding the comments.

Ques2 : Define a function int[] reverse(int a[], int n) to reverse the first n elements of the integer array a. Eg reverse([2,5,3,4], 3) should give output [3,5,2,4]
Use constant memory and O(n) complexity.

Ques3 : Write a function char[] GenerateNextDate(char[]) such that if a date of the format “23Jan2012” is input, the next date should be produced.
Eg : Input – “12Dec1987”
Output – “13Dec1987”
Please remember the input and output are both strings.
Each ques is of 5 marks. Cut off for this round is 7/15.
If you clear these rounds, you will be called to their Gurgaon office where there will be another coding test of higher difficulty with same pattern as previous test – 3ques/5 marks each. I remember 2 questions.
Ques 1 : To print
1 2 3 4 5
2 1 2 3 4
3 2 1 2 3
4 3 2 1 2
5 4 3 2 1

Ques 2: Given an array, separate positives and negatives.
For eg. Input array – [9,4,-3,-2,1,-1,5,7,-9,-5]
Output array – [9,4,1,5,7,-3,-2,-1,-9,-5]
After this test, you will have a face-off technical in which you’ll be asked questions based on the solutions you have given for these problems and the logic you have applied, no other questions on any subject.
An HR round takes place after this, it is just a formality. So the main thing is you have to write good code that’s it. You will be selected.

Leave a Comment

Your email address will not be published. Required fields are marked *

Scroll to Top