Placement Papers
TCS, Infosys, Wipro, Cognizant actual papers
312 Questions 12 Topics Take Test
Advertisement
Showing 1–10 of 312 questions
Q.1 Medium Cognizant Questions Cognizant
In a sequence, each number is the sum of the previous two numbers. If the 5th number is 20 and the 6th number is 32, what is the 4th number?
A 10
B 12
C 15
D 18
Correct Answer:  B. 12
EXPLANATION

Let the 4th number be x. Then 5th number = previous number + x. If 5th = 20 and 6th = 32, then 6th = 5th + 5th_previous, so 32 = 20 + (5th_previous). Therefore, 5th_previous = 12. Since 5th_previous is the 4th number, the answer is 12.

Take Test
Q.2 Medium Cognizant Questions Cognizant
A train travels from City A to City B at 60 km/h and returns at 40 km/h. The total distance between the two cities is 240 km. What is the average speed of the train for the entire journey?
A 48 km/h
B 50 km/h
C 52 km/h
D 55 km/h
Correct Answer:  A. 48 km/h
EXPLANATION

Average speed = Total Distance / Total Time. Distance one way = 240 km. Time from A to B = 240/60 = 4 hours. Time from B to A = 240/40 = 6 hours. Total Distance = 480 km, Total Time = 10 hours. Average Speed = 480/10 = 48 km/h.

Take Test
Q.3 Medium Google Questions Google
In TCP/IP model, which layer handles IP addresses?
A Application Layer
B Transport Layer
C Internet Layer
D Link Layer
Correct Answer:  C. Internet Layer
EXPLANATION

The Internet Layer (Layer 3) handles IP addresses and routing. Transport Layer (Layer 4) handles ports.

Take Test
Q.4 Medium Google Questions Google
What does MapReduce do?
A Reduces maps to a single value
B Processes large datasets by mapping operations and reducing results
C Only works with arrays
D Is used only in front-end development
Correct Answer:  B. Processes large datasets by mapping operations and reducing results
EXPLANATION

MapReduce is a programming model for processing large datasets in parallel by mapping data and then reducing results.

Take Test
Q.5 Medium Google Questions Google
What principle is followed when designing Google's systems?
A Monolithic architecture
B Distributed systems with horizontal scalability
C Centralized database model
D Sequential processing
Correct Answer:  B. Distributed systems with horizontal scalability
EXPLANATION

Google designs distributed systems that can scale horizontally across many machines to handle billions of requests.

Take Test
Advertisement
Q.6 Medium Google Questions Google
In microservices architecture, what is an API Gateway?
A A server that stores APIs
B A single entry point for client requests to multiple microservices
C A database for API data
D A security firewall
Correct Answer:  B. A single entry point for client requests to multiple microservices
EXPLANATION

API Gateway is a server that acts as an intermediary between clients and microservices, handling routing, authentication, and load balancing.

Take Test
Q.7 Medium Google Questions Google
What is the correct output of: print(2 ** 3 ** 2) in Python?
A 64
B 512
C 8
D 256
Correct Answer:  B. 512
EXPLANATION

Exponentiation is right-associative in Python. 32 = 9, then 29 = 512

Take Test
Q.8 Medium Google Questions Google
In dynamic programming, what is memoization?
A Breaking problem into subproblems
B Storing results of subproblems to avoid recomputation
C Creating a memo
D Sorting results
Correct Answer:  B. Storing results of subproblems to avoid recomputation
EXPLANATION

Memoization is an optimization technique where results of expensive function calls are cached and returned when same inputs occur again.

Take Test
Q.9 Medium Google Questions Google
Which sorting algorithm is stable and has O(n log n) worst-case complexity?
A QuickSort
B MergeSort
C HeapSort
D Selection Sort
Correct Answer:  B. MergeSort
EXPLANATION

MergeSort has O(n log n) worst-case and is stable. QuickSort is O(n²) worst-case, HeapSort is not stable.

Take Test
Q.10 Medium Google Questions Google
What is the space complexity of QuickSort?
A O(1)
B O(log n)
C O(n)
D O(n log n)
Correct Answer:  B. O(log n)
EXPLANATION

QuickSort uses O(log n) space for the recursion call stack in the average case.

Take Test
IGET
iget AI
Online · Ask anything about exams
Hi! 👋 I'm your iget AI assistant.

Ask me anything about exam prep, MCQ solutions, study tips, or strategies! 🎯
UPSC strategy SSC CGL syllabus Improve aptitude NEET Biology tips