Cognizant Interview Preparation
Comprehensive guide to Cognizant interview preparation including technical and HR interview questions
Understand the Problem
Problem Statement
The Cognizant is an American multinational IT company with its headquarter in the USA. In this article, we are provided various types of interview questions that are helpful in the interview process. So the applied candidates should read the entire content in this article without leaving a single word.
Constraints
- Content must be suitable for technical and HR interview preparation
- Questions should cover multiple domains (Control Systems, Electronics, Programming, etc.)
- Answers should be concise and technically accurate
- Code examples should be well-formatted and executable
Examples
Control System Interview Questions
- What are the cooling methods to cool a transformer?
- How do we specify the rating of a transformer?
These questions test fundamental knowledge of electrical engineering concepts and transformer operation principles.
Mobile Computing Interview Questions
- Write a function that returns the factorial of a number.
- What are the data structures?
These questions assess programming skills and understanding of basic computer science concepts.
HR Interview Questions
- Tell me something about yourself?
- Why do you want to work for us?
These questions evaluate communication skills, motivation, and cultural fit for the organization.
Solution
// Sample C program for factorial calculation
#include <stdio.h>
int factorial(int n) {
if (n <= 1) return 1;
return n * factorial(n - 1);
}
int main() {
int num;
printf("Enter a number: ");
scanf("%d", &num);
printf("Factorial of %d is %d\n", num, factorial(num));
return 0;
}This C program demonstrates a recursive factorial function:
- Function
factorial()handles base case (n <= 1) - Recursive call multiplies n by factorial(n-1)
- Main function reads input and displays result