Add office photos
Nagarro logo
Engaged Employer

Nagarro

Verified
4.0
based on 4.1k Reviews
Video summary
Filter interviews by
Associate Engineer
Fresher
Clear (2)

Nagarro Associate Engineer Interview Questions and Answers for Freshers

Updated 5 Feb 2024

Q1. Count Ways To Reach The N-th Stair Problem Statement

You are given a number of stairs, N. Starting at the 0th stair, you need to reach the Nth stair. Each time you can either climb one step or two steps. You ha...read more

Ans.

The problem involves finding the number of distinct ways to climb to the Nth stair by taking one or two steps at a time.

  • Use dynamic programming to solve this problem efficiently.

  • The number of ways to reach the Nth stair is the sum of the number of ways to reach the (N-1)th stair and the (N-2)th stair.

  • Handle large inputs by taking modulo 10^9+7 to avoid overflow.

  • Example: For N=3, there are 3 ways to climb to the third stair: (0, 1, 2, 3), (0, 2, 3), and (0, 1, 3).

Add your answer
right arrow

Q2. Trailing Zeros in Factorial Problem

Find the number of trailing zeroes in the factorial of a given number N.

Input:

The first line contains an integer T representing the number of test cases.
Each of the followi...read more
Ans.

Count the number of trailing zeros in the factorial of a given number.

  • To find the number of trailing zeros in N!, count the number of factors of 5 in the prime factorization of N.

  • Each factor of 5 contributes to a trailing zero in the factorial.

  • For example, for N=10, there are 2 factors of 5 in the prime factorization (5 and 10), so there are 2 trailing zeros.

Add your answer
right arrow

Q3. Quick and merge time complexity and when worst case happens in quick sort

Ans.

Quick sort has O(n log n) time complexity on average, O(n^2) worst case. Merge sort has O(n log n) time complexity always.

  • Quick sort has an average time complexity of O(n log n) due to its divide-and-conquer approach.

  • Worst case for quick sort occurs when the pivot element is either the smallest or largest element in the array, leading to O(n^2) time complexity.

  • Merge sort always has a time complexity of O(n log n) due to its consistent splitting and merging of subarrays.

Add your answer
right arrow

Q4. Remove a linked list node without head or tail pointer given

Ans.

Removing a node from a linked list without head or tail pointer

  • Use the node to be removed's next node to copy its data and then delete the next node

  • Update the current node's next pointer to skip the next node

Add your answer
right arrow
Discover Nagarro interview dos and don'ts from real experiences

Q5. Your favorite programming language and why

Ans.

My favorite programming language is Python because of its simplicity, readability, and versatility.

  • Python is known for its clean and readable syntax, making it easy to learn and understand.

  • Python has a large standard library and many third-party libraries, allowing for rapid development of a wide range of applications.

  • Python is versatile and can be used for web development, data analysis, machine learning, automation, and more.

Add your answer
right arrow

Q6. Remove nth element from array

Ans.

Remove the nth element from an array of strings

  • Use the splice method to remove the element at the specified index

  • Remember that array indices start at 0

  • Example: array.splice(n, 1) will remove the element at index n

Add your answer
right arrow

More about working at Nagarro

Back
Awards Leaf
AmbitionBox Logo
#2 Best Large Company - 2022
Awards Leaf
Awards Leaf
AmbitionBox Logo
#1 Best IT/ITES Company - 2022
Awards Leaf
Contribute & help others!
Write a review
Write a review
Share interview
Share interview
Contribute salary
Contribute salary
Add office photos
Add office photos

Interview Process at Nagarro Associate Engineer for Freshers

based on 4 interviews
5 Interview rounds
Resume Shortlist Round
Aptitude Test Round
Coding Test Round
Technical Round
HR Round
View more
interview tips and stories logo
Interview Tips & Stories
Ace your next interview with expert advice and inspiring stories

Top Associate Engineer Interview Questions from Similar Companies

TCS Logo
3.7
 • 22 Interview Questions
Quess Logo
3.9
 • 10 Interview Questions
View all
Recently Viewed
INTERVIEWS
Eduonix Learning Solutions
No Interviews
INTERVIEWS
Tech Mahindra
5.6k top interview questions
INTERVIEWS
Tata Motors
5.6k top interview questions
LIST OF COMPANIES
Schneider Electric
Locations
SALARIES
Honda Motorcycle & Scooter
INTERVIEWS
Navigators Software
10 top interview questions
SALARIES
Honda Motorcycle & Scooter
SALARIES
Honda Motorcycle & Scooter
REVIEWS
Tata Motors
No Reviews
INTERVIEWS
iOPEX Technologies
10 top interview questions
Share an Interview
Stay ahead in your career. Get AmbitionBox app
play-icon
play-icon
qr-code
Helping over 1 Crore job seekers every month in choosing their right fit company
75 Lakh+

Reviews

5 Lakh+

Interviews

4 Crore+

Salaries

1 Cr+

Users/Month

Contribute to help millions

Made with ❤️ in India. Trademarks belong to their respective owners. All rights reserved © 2024 Info Edge (India) Ltd.

Follow us
  • Youtube
  • Instagram
  • LinkedIn
  • Facebook
  • Twitter