Code360 powered by Coding Ninjas X Naukri.com. Code360 powered by Coding Ninjas X Naukri.com
Cognizant interview experience Real time questions & tips from candidates to crack your interview

Genc Next

Cognizant
upvote
share-icon
3 rounds | 3 Coding problems

Interview preparation journey

expand-icon
Preparation
Duration: 2 months
Topics: C, C++, java, Python, c#.net, sql, some certifications on Machine learning
Tip
Tip

Tip 1 : confidence is most important.
Tip 2 : explaining projects plays a key role.
 

Application process
Where: Campus
Eligibility: 6.5 CGPA
Resume Tip
Resume tip

Tip 1 : you should be very clear what you have written in your resume.
Tip 2 : projects should be very clear

Interview rounds

01
Round
Medium
Online Coding Interview
Duration120 Minutes
Interview date18 Oct 2020
Coding problem1

We have aptitude, reasoning and verbal.

1. Sort Array

Moderate
15m average time
85% success
0/80
Asked in companies
SprinklrTata Consultancy Services (TCS)BNY Mellon

You are given an array consisting of 'N' positive integers where each integer is either 0 or 1 or 2. Your task is to sort the given array in non-decreasing order.

Note :
1. The array consists of only 3 distinct integers 0, 1, 2.
2. The array is non-empty.
Try solving now
02
Round
Easy
Online Coding Interview
Duration60 minutes
Interview date15 Nov 2020
Coding problem1

Advanced Coding round

1. Minimum steps to reach target by a Knight

Moderate
25m average time
60% success
0/80
Asked in companies
MicrosoftIntuitSwiggy

You have been given a square chessboard of size ‘N x N’. The position coordinates of the Knight and the position coordinates of the target are also given.

Your task is to find out the minimum steps a Knight will take to reach the target position.

alt text

Example:
knightPosition: {3,4}
targetPosition: {2,1}

alt text

The knight can move from position (3,4) to positions (1,3), (2,2) and (4,2). Position (4,2) is selected and the ‘stepCount’ becomes 1. From position (4,2), the knight can directly jump to the position (2,1) which is the target point and ‘stepCount’ becomes 2 which is the final answer. 

Note:

1. The coordinates are 1 indexed. So, the bottom left square is (1,1) and the top right square is (N, N).

2. The knight can make 8 possible moves as given in figure 1.

3. A Knight moves 2 squares in one direction and 1 square in the perpendicular direction (or vice-versa).
Try solving now
03
Round
Medium
Face to Face
Duration60 Minutes
Interview date15 Dec 2020
Coding problem1

I got the link a day before and my interview was scheduled at 6Pm.

1. Ways To Make Coin Change

Moderate
20m average time
80% success
0/80
Asked in companies
MicrosoftTata Consultancy Services (TCS)Flipkart

You are given an infinite supply of coins of each of denominations D = {D0, D1, D2, D3, ...... Dn-1}. You need to figure out the total number of ways W, in which you can make a change for value V using coins of denominations from D. Print 0, if a change isn't possible.

Try solving now

Here's your problem of the day

Solving this problem will increase your chance to get selected in this company

Skill covered: Programming

How do you write a single-line comment in C++?

Choose another skill to practice
Start a Discussion
Similar interview experiences
company logo
Genc Next
2 rounds | 5 problems
Interviewed by Cognizant
668 views
0 comments
0 upvotes
company logo
Genc Next
2 rounds | 7 problems
Interviewed by Cognizant
820 views
0 comments
0 upvotes
company logo
Genc Next
3 rounds | 6 problems
Interviewed by Cognizant
514 views
0 comments
0 upvotes
company logo
Genc Next
3 rounds | 9 problems
Interviewed by Cognizant
530 views
0 comments
0 upvotes