CS basics · free timed test
A timed sectional test: 10 to 50 questions (you choose) on 8 topics, drawn fresh each attempt from 362 questions; no negative marking. Pass mark 60%.
Computer science fundamentals for technical rounds of IT campus hiring: C and C++ output, object-oriented programming, data structures, algorithms and complexity, DBMS and SQL, operating systems, computer networks, and Java and Python basics. Pick 10, 25 or 50 multiple-choice questions; no negative marking. This is not a coding round.
Questions · fresh ones every attempt
Drawn from 362 questions, so every retake is a new paper.
10 to 50 questions, four options each, drawn fresh on every attempt from these topics. The result page scores every topic separately so you can see where the marks went.
Good forplacementsCS fundamentalstechnical MCQDBMSoperating systemsOOPcampus hiring
6 questions of the kind Placement CS Fundamentals Test asks, with answers. Try each one before you open the answer; the test itself draws a fresh set.
Q1 · Algorithms and complexity
A directed graph has edges A->B, A->C, B->D, C->D and D->E. Which of these is a valid topological order?
Answer: C. A C B D E
Every edge u->v needs u before v. A C B D E satisfies all five edges. A B D C E puts D before C despite C->D; B A C D E puts B before A; A B C E D puts E before D. B and C can come in either order, since neither depends on the other.
Q2 · C and C++ output
What does this C++ program print? (Assume the needed standard headers are included and using namespace std; is in effect.) int main() { int v[] = {4, 1, 3, 2}; sort(v, v + 4); cout << v[1] << v[3]; return 0; }
Answer: A. 24
std::sort(v, v + 4) sorts the whole array in ascending order, giving {1, 2, 3, 4}. Indices start at 0, so v[1] is 2 and v[3] is 4, and the output is 24. 14 reads index 0 instead of index 1, and 23 treats v[3] as the third element.
Q3 · Data structures
What is the maximum number of nodes in a binary tree of height 4, with the root at height 0?
Answer: D. 31
Level k can hold at most 2 to the power k nodes. Levels 0 to 4 give 1 + 2 + 4 + 8 + 16 = 31, which is 2 to the power (h + 1) minus 1. 15 is the answer for height 3, and 16 is the number of nodes on level 4 alone.
Q4 · Java and Python basics
What does this Python code print? marks = {"Riya": 82} print(marks.get("Aman", 0))
Answer: D. 0
dict.get(key, default) returns the value for key if it exists, otherwise the default. "Aman" is not a key, so 0 is printed. Without the second argument, get would return None. Only the subscript form marks["Aman"] raises a KeyError for a missing key.
Q5 · Computer networks
Why do Wi-Fi networks use CSMA/CA instead of CSMA/CD?
Answer: D. A wireless station usually cannot detect a collision while transmitting, and hidden stations may not hear each other
A radio transmitting at full power cannot reliably hear a much weaker colliding signal, and two stations out of each other's range can both reach the access point (the hidden-terminal problem). So 802.11 tries to avoid collisions with random backoff, optional RTS/CTS and acknowledgements instead of detecting them.
Q6 · Object-oriented programming
In C++, class D : private B { }; What access do B's public members have inside D's interface?
Answer: D. They become private members of D
With private inheritance, public and protected members of B become private members of D. D's own member functions can still use them, but outside code and D's subclasses cannot. Private members of B stay inaccessible to D either way.
Free guides
It starts when you press Start and keeps running if you reload, switch tabs or lose connection. Under a minute left, the clock turns red.
Every change is saved within seconds and again every ten seconds. Leave and come back while time remains and the test resumes where you were.
When the clock hits zero, whatever you have answered is submitted and scored. Unanswered questions count as wrong; there is no negative marking.
You can have one attempt of this test running at a time. Submit it (or let it expire) to start a fresh one with a new timer.
Keys 1 to 4 choose an option, the left and right arrows move between questions, and the palette jumps anywhere. Flag a question to come back to it.
The score tells you where you stand; these are where the preparation happens.
Interview Essentials
Interview Essentials
From the registration desk to the technical panel, one clear voice
GD & Extempore
Three formats, one toolkit
20 min · 25 Qs
Free · pass 60%