
Data Structures Quiz

Quiz
•
Computers
•
12th Grade
•
Hard
Sudharsanan G
Used 1+ times
FREE Resource
Student preview

25 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the time complexity of inserting an element into a max-heap?
O(1)
O(log n)
O(n)
O(n log n)
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
In a max-heap, the root node contains the:
Maximum element
Minimum element
Middle element
Random element
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following is true for a min-heap?
Parent node is always smaller than or equal to its children
Parent node is always greater than or equal to its children
Leaf nodes are greater than their parents
Elements are sorted in non-decreasing order
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the time complexity of extracting the maximum element from a max-heap?
O(1)
O(log n)
O(n)
O(n log n)
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following applications can be implemented using a heap?
Priority queue
Graph traversal
Binary search
Depth-first search
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the time complexity of searching for an element in a hash table in the average case?
O(1)
O(log n)
O(n)
O(n log n)
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following techniques is used to handle collisions in a hash table?
Linear probing
Binary search
Depth-first search
Breadth-first search
Create a free account and access millions of resources
Popular Resources on Wayground
50 questions
Trivia 7/25

Quiz
•
12th Grade
11 questions
Standard Response Protocol

Quiz
•
6th - 8th Grade
11 questions
Negative Exponents

Quiz
•
7th - 8th Grade
12 questions
Exponent Expressions

Quiz
•
6th Grade
4 questions
Exit Ticket 7/29

Quiz
•
8th Grade
20 questions
Subject-Verb Agreement

Quiz
•
9th Grade
20 questions
One Step Equations All Operations

Quiz
•
6th - 7th Grade
18 questions
"A Quilt of a Country"

Quiz
•
9th Grade