
HEAP

Quiz
•
Computers
•
Professional Development
•
Medium
PVS SAIRAM
Used 1+ times
FREE Resource
10 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
Which of the following are min heaps?
A
B
C
D
2.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
How many swaps are made in the min heap when inserting the value 18?
0
1
2
3
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What operation has efficiency O(1) using the java.util.PriorityQueue class?
Peek()
Pop()
Poll()
Remove()
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following PriorityQueue<E> methods will throw an exception when used on an empty queue?
remove()
poll()
pop()
peek()
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
When removing the root from a min heap, what is the first step?
Replace the root with the next smallest value from the tree
Replace the root with the leaf furthest to the left on the bottom level of the tree
Replace the root with the leaf furthest to the right on the bottom level of the tree
Replace the root with the smallest of its children
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
The formula for finding the right child of a node in a heap stored in an array is ________ . (The root is at index 0)
( 2 * Parent ) + 2
( 2 * Parent ) + 1
( 2 * Parent ) + 3
( 2 * Parent )
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the process of 'heapifying' in Heap Sort?
Arranging elements in a heap data structure
Sorting elements in reverse order
Removing elements from the heap
Randomly shuffling the elements
Create a free account and access millions of resources
Similar Resources on Wayground
10 questions
Day 2

Quiz
•
Professional Development
10 questions
IT ENGLISH: Research Project Topics - Web Design

Quiz
•
Professional Development
10 questions
CIT JULY 2022

Quiz
•
Professional Development
14 questions
CAD-CAM

Quiz
•
12th Grade - Professi...
15 questions
Queues

Quiz
•
11th Grade - Professi...
10 questions
SQL Server Indexes

Quiz
•
Professional Development
10 questions
SENZ AIOT SAVANTS - JV & JS

Quiz
•
Professional Development
10 questions
Pretest JNCIA

Quiz
•
Professional Development
Popular Resources on Wayground
20 questions
Brand Labels

Quiz
•
5th - 12th Grade
10 questions
Ice Breaker Trivia: Food from Around the World

Quiz
•
3rd - 12th Grade
25 questions
Multiplication Facts

Quiz
•
5th Grade
20 questions
ELA Advisory Review

Quiz
•
7th Grade
15 questions
Subtracting Integers

Quiz
•
7th Grade
22 questions
Adding Integers

Quiz
•
6th Grade
10 questions
Multiplication and Division Unknowns

Quiz
•
3rd Grade
10 questions
Exploring Digital Citizenship Essentials

Interactive video
•
6th - 10th Grade