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

Genc Next

Cognizant
upvote
share-icon
3 rounds | 5 Coding problems

Interview preparation journey

expand-icon
Preparation
Duration: 8 months
Topics: Data Structures, Object-Oriented Programming, Java, HTML, CSS, JavaScript, React.js
Tip
Tip

Tip 1 : Focus on Object-Oriented Programming
Tip 2 : Make at least 1 major project and 2 small projects
Tip 3 : Look up Java interview questions and do mock interviews with friends

Application process
Where: Campus
Eligibility: 60% in Graduation
Resume Tip
Resume tip

Tip 1 : Use a properly structured resume format of a single page
Tip 2 : Projects must be explained well on the resume

Interview rounds

01
Round
Easy
Online Coding Interview
Duration180 minutes
Interview date2 May 2022
Coding problem2

1. King Placement

Moderate
40m average time
50% success
0/80
Asked in company
Cognizant

This is a typical chess game where your opponent first places a random number of Knights, Rooks, Bishop, and Queens on an ‘N*N’ chessboard, and then you have to place your king safely on the chessboard such that it should not be under attack by any piece.

Given an ‘N*N’ chessboard with ‘K’ number of Knights, ‘R’ number of Rooks, ‘B’ number of Bishops, and ‘Q’ number of queens. Your task is to find out the number of squares on the chessboard such that your King is not checked by any of your opponent's pieces.

HOW TO PLAY CHESS

EXAMPLE :
Refer to the explanation of Sample Input 1 for better understanding.
Problem approach

Step 1 : First take user input correctly and save it in correct type of variables. 
Step 2 : Read the problem statement again and implement the business logic and save your output in a variable. In the end print your answer in the console. 
Step 3 : Keep time for debugging your solution. 
Tip : Keeping the business logic separate from answer helps during debugging.

Try solving now

2. Least Common Ancestor

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

You are given an arbitrary binary tree with N nodes, whose nodes have their values in the range of integers. You are given two nodes x, y from the tree. You have to print the least common ancestor of these nodes.

Least common ancestor of two nodes x, y in a tree or directed acyclic graph is the lowest node that has both nodes x, y as its descendants.

For example look at the tree below, the LCA of node 1 and 5 is 3.

Note :

You have to return the deepest node which has both x, y as its descendants.
There may be cases where one of u or v is not present in the tree. In those cases, the reference provided to u or v will be NULL.
Try solving now
02
Round
Medium
Video Call
Duration60 minutes
Interview date2 Jun 2022
Coding problem2

Timing is mailed to you.
It is an online video call.

1. SQL Queries

How to Select TOP 5 Salaries from Employee Table in SQL

How to join three tables and group them on a certain criteria?

Problem approach

Tip 1 : Just have basic understanding of functions.
Tip 2 : Practice common interview questions.

2. OOPS Question

What are the differences between abstract class and interface?

What are the differences between Inheritance and Polymorphism?

Explain Inheritance with an example.

Problem approach

Tip 1 : Go through Java interview questions from internet

 

03
Round
Easy
HR Round
Duration10 minutes
Interview date1 Jul 2023
Coding problem1

1. Basic HR Questions

Are you ready to relocate? 

Just provide a College id card, Aadhaar card, Pan card, etc for document verification

Problem approach

Tip 1 : Just be prepared with documents and say yes to the relocation question.

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
1733 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