Cognizant interview experience Real time questions & tips from candidates to crack your interview

Genc Next

Cognizant
upvote
share-icon
3 rounds | 6 Coding problems

Interview preparation journey

expand-icon
Preparation
Duration: 2 Months
Topics: Python, OOPS, OS, CN, DBMS, Probelm solving
Tip
Tip

Tip 1 : Should be familiar with basic concepts
Tip 2 : Should be able to communicate efficiently
Tip 3 : Do atleast one good project

Application process
Where: Campus
Eligibility: 7CGPA, No backlogs
Resume Tip
Resume tip

Tip 1 : It's better to be fit in single page
Tip 2 : Have clear understanding of everything mentioned in Resume

Interview rounds

01
Round
Medium
Online Coding Test
Duration90 Minutes
Interview date7 Jul 2021
Coding problem2

It's having 2 coding questions which are easy-medium, medium-hard coding questions

1. Longest Common Subsequence

Moderate
39m average time
0/80
Asked in companies
PayPalShareChatOla

Given two strings, 'S' and 'T' with lengths 'M' and 'N', find the length of the 'Longest Common Subsequence'.

For a string 'str'(per se) of length K, the subsequences are the strings containing characters in the same relative order as they are present in 'str,' but not necessarily contiguous. Subsequences contain all the strings of length varying from 0 to K.

Example :
Subsequences of string "abc" are:  ""(empty string), a, b, c, ab, bc, ac, abc.
Problem approach

It's common LC problem and was able to solve optimally

Try solving now

2. Rat In A Maze

Easy
15m average time
85% success
0/40
Asked in companies
OlaZSMicrosoft

You are given a starting position for a rat which is stuck in a maze at an initial point (0, 0) (the maze can be thought of as a 2-dimensional plane). The maze would be given in the form of a square matrix of order 'N' * 'N' where the cells with value 0 represent the maze’s blocked locations while value 1 is the open/available path that the rat can take to reach its destination. The rat's destination is at ('N' - 1, 'N' - 1). Your task is to find all the possible paths that the rat can take to reach from source to destination in the maze. The possible directions that it can take to move in the maze are 'U'(up) i.e. (x, y - 1) , 'D'(down) i.e. (x, y + 1) , 'L' (left) i.e. (x - 1, y), 'R' (right) i.e. (x + 1, y).

Note:
Here, sorted paths mean that the expected output should be in alphabetical order.
For Example:
Given a square matrix of size 4*4 (i.e. here 'N' = 4):
1 0 0 0
1 1 0 0
1 1 0 0
0 1 1 1 
Expected Output:
DDRDRR DRDDRR 
i.e. Path-1: DDRDRR and Path-2: DRDDRR

The rat can reach the destination at (3, 3) from (0, 0) by two paths, i.e. DRDDRR and DDRDRR when printed in sorted order, we get DDRDRR DRDDRR.
Try solving now
02
Round
Medium
Face to Face
Duration60 Minutes
Interview date11 Aug 2022
Coding problem3

The timing was from 2-3pm and it was on microsoft teams,
and the interviewer was so friendly and asked questions on basic core topics and some development related questions
And interviewer focussed mainly on project which was mentioned in resume

1. Operating System Questions

Asked about multithreading, OS types, Pagination and memory management

Problem approach

Tip 1 : Have good understanding of OS concepts
 

2. DBMS based question

Asked few quesries and asked about consistency, ACID properties

Problem approach

Tip 1:Good understanding of Queries is better
 

3. Sort An Array According To The Count Of Set Bits

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

You are given an array consisting of N positive integers, and your task is to sort the array in decreasing order of count of set bits in the binary representation of the integers present in the array.

In other words, you have to modify the array such that an integer with more number of set bits should appear before the integer which has lesser number of set bits in its binary representation.

The number of set bits is nothing but the number of 1s present in the binary representation of the integer. For example, the number of set bits in 5(0101) is equal to 2.

Note :

1. If any two numbers have the same count of set bits, then in the sorted array they will appear in the order in which they appear in the original array. For example, let the array be { 2, 4, 3}, in this case, both 2 and 4 have the same number of set bits so the answer will be {3, 2, 4} and not {3, 4, 2}, because in the original array 2 appears before 4.

2. The array may contain duplicate elements.
Problem approach

Started with problem statement and explained briefly and written code

Try solving now
03
Round
Easy
HR Round
Duration30 Minutes
Interview date31 Aug 2022
Coding problem1

It's more like formality and was asked basic details like availability during internship and location

1. Basic HR questions

Asked availability for internship

Asked about location preference

Here's your problem of the day

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

Skill covered: Programming

To make an AI less repetitive in a long paragraph, you should increase:

Choose another skill to practice
Similar interview experiences
company logo
Genc Next
2 rounds | 5 problems
Interviewed by Cognizant
1249 views
0 comments
0 upvotes
company logo
Genc Next
2 rounds | 7 problems
Interviewed by Cognizant
1734 views
0 comments
0 upvotes
company logo
Genc Next
3 rounds | 6 problems
Interviewed by Cognizant
867 views
0 comments
0 upvotes
company logo
Genc Next
3 rounds | 9 problems
Interviewed by Cognizant
1064 views
0 comments
0 upvotes