# Coforge Core CS Questions with Answers

8 previously-asked core cs questions from Coforge's hiring process, each with the correct answer and a worked explanation. Written against the company's actual test pattern.

_Source: Astra (https://useastra.in). Updated 2026-09-05._

### 1. Which statement about a primary key is correct?

A. It uniquely identifies each row and cannot be null
B. It always allows duplicate values
C. It can be null
D. It can only be a text column

**Answer:** It uniquely identifies each row and cannot be null

**Explanation:** A primary key uniquely identifies a row and does not permit null values.

### 2. Which OSI layer provides end to end reliable delivery?

A. Network
B. Transport
C. Session
D. Application

**Answer:** Transport

**Explanation:** The Transport layer (for example TCP) ensures reliable, ordered end to end delivery.

### 3. Which of the following is a linear data structure?

A. Tree
B. Graph
C. Array
D. Heap

**Answer:** Array

**Explanation:** An array stores elements sequentially, making it linear; trees, graphs, and heaps are non-linear.

### 4. Runtime polymorphism in OOP is achieved through?

A. Overloading
B. Overriding
C. Encapsulation
D. Abstraction

**Answer:** Overriding

**Explanation:** Method overriding is resolved at runtime based on the object type, giving runtime polymorphism.

### 5. A process that is loaded in memory and waiting for CPU time is in which state?

A. Running
B. Ready
C. Waiting
D. Terminated

**Answer:** Ready

**Explanation:** A process in memory waiting only for the CPU is in the ready state.

### 6. Which normal form addresses multivalued dependencies?

A. 3NF
B. BCNF
C. 4NF
D. 2NF

**Answer:** 4NF

**Explanation:** Fourth Normal Form removes multivalued dependencies.

### 7. Which of the following is NOT a built in data type in C?

A. int
B. char
C. float
D. string

**Answer:** string

**Explanation:** C has int, char, and float, but not a native string type; strings are char arrays.

### 8. What is the main purpose of DNS?

A. Resolve domain names to IP addresses
B. Encrypt network data
C. Route packets between subnets
D. Assign MAC addresses

**Answer:** Resolve domain names to IP addresses

**Explanation:** The Domain Name System translates human readable domain names into IP addresses.

More Coforge preparation, including the full recruitment process: https://useastra.in/campus/coforge
