MCQ Collection
Data Structures 300 Unique MCQs
Practice Data Structures 300 Unique questions with answers and explanations.
Choose an option to check your answer.
A.
Full Binary Tree
B.
Open Addressing
C.
Breadth-First Search
D.
Adjacency Matrix
Show Answer
Correct Answer: D. Adjacency Matrix
Explanation:
Adjacency Matrix fits because it supports dense graphs and constant-time edge-existence tests and its space usage is quadratic in the number of vertices.
Both clues point to this choice.
Choose an option to check your answer.
A.
Adjacency List
B.
Hash Table
C.
Max-Heap
D.
Splay Tree
Show Answer
Correct Answer: A. Adjacency List
Explanation:
Adjacency List is a graph representation storing the neighbors of each vertex.
This description distinguishes it from the other choices.
Choose an option to check your answer.
A.
efficient insertion or deletion when a node reference is available
B.
sparse graphs
C.
function-call management and undo operations
D.
simple hash-table implementations
Show Answer
Correct Answer: B. sparse graphs
Explanation:
Adjacency List is commonly used for sparse graphs.
Its design supports this task efficiently or naturally.
Choose an option to check your answer.
A.
it is generally not stable
B.
the highest- or lowest-priority item is served first
C.
its space usage is proportional to vertices plus edges
D.
its merge step usually needs auxiliary storage for arrays
Show Answer
Correct Answer: C. its space usage is proportional to vertices plus edges
Explanation:
The defining property is that its space usage is proportional to vertices plus edges.
The other statements describe different structures or concepts.
Choose an option to check your answer.
A.
Undirected Graph
B.
Stable Sorting
C.
Breadth-First Search
D.
Suffix Tree
Show Answer
Correct Answer: A. Undirected Graph
Explanation:
Undirected Graph is a graph whose edges have no direction.
This description distinguishes it from the other choices.
Choose an option to check your answer.
A.
scheduling tasks with dependencies
B.
modeling symmetric relationships
C.
substring search and text indexing
D.
dense graphs and constant-time edge-existence tests
Show Answer
Correct Answer: B. modeling symmetric relationships
Explanation:
Undirected Graph is commonly used for modeling symmetric relationships.
Its design supports this task efficiently or naturally.
Choose an option to check your answer.
A.
very deep recursion can cause stack overflow
B.
each node's balance factor is typically -1, 0, or 1
C.
each edge connects two vertices bidirectionally
D.
the minimum element is stored at the root
Show Answer
Correct Answer: C. each edge connects two vertices bidirectionally
Explanation:
The defining property is that each edge connects two vertices bidirectionally.
The other statements describe different structures or concepts.
Choose an option to check your answer.
A.
Binary Search
B.
Skip List
C.
Radix Tree
D.
Undirected Graph
Show Answer
Correct Answer: D. Undirected Graph
Explanation:
Undirected Graph fits because it supports modeling symmetric relationships and each edge connects two vertices bidirectionally.
Both clues point to this choice.
Choose an option to check your answer.
A.
Weighted Graph
B.
Garbage Collection
C.
Adjacency List
D.
Suffix Array
Show Answer
Correct Answer: A. Weighted Graph
Explanation:
Weighted Graph is a graph whose edges or vertices carry numeric costs or values.
This description distinguishes it from the other choices.
Choose an option to check your answer.
A.
tracking return addresses and local state
B.
shortest-path and network optimization problems
C.
fast random access when the index is known
D.
sparse graphs
Show Answer
Correct Answer: B. shortest-path and network optimization problems
Explanation:
Weighted Graph is commonly used for shortest-path and network optimization problems.
Its design supports this task efficiently or naturally.
Choose an option to check your answer.
A.
each edge connects two vertices bidirectionally
B.
there is at most one binomial tree of each degree
C.
path quality can depend on the sum of weights
D.
after each full pass, an extreme element reaches its final region
Show Answer
Correct Answer: C. path quality can depend on the sum of weights
Explanation:
The defining property is that path quality can depend on the sum of weights.
The other statements describe different structures or concepts.
Choose an option to check your answer.
A.
Topological Sort
B.
Quick Sort
C.
Selection Sort
D.
Weighted Graph
Show Answer
Correct Answer: D. Weighted Graph
Explanation:
Weighted Graph fits because it supports shortest-path and network optimization problems and path quality can depend on the sum of weights.
Both clues point to this choice.