
Heaps Quiz

Quiz
•
Computers
•
University
•
Hard
Jordan Burgess
FREE Resource
15 questions
Show all answers
1.
MULTIPLE SELECT QUESTION
1 min • 1 pt
What are the two storage rules that make heaps special?
The tree is a complete binary tree
Every level except the deepest must have as many nodes as possible
A parent's item is never less than the item of any of its children
The item contained in a node is greater than or equal to the items of the node's children
2.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
How can a heap be implemented using an array?
By storing the root node in position 1 and locating the children randomly
By storing the root node in position 1 and locating the children mathematically
By storing the root node in position 0 and locating the children mathematically
By storing the root node in position 0 and locating the children randomly
3.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
What is a priority queue?
A queue in which items are stored based on their insertion order
A queue in which items are stored based on their alphabetical order
A queue in which each item has a priority assigned to it
A queue in which items are stored based on their numerical order
4.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
What are the two key operations for a heap?
Adding a new entry and removing the entry with the highest priority
Adding a new entry and removing the entry with the middle priority
Adding a new entry and removing the entry with the lowest priority
Adding a new entry and removing any random entry
5.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
What is the first step in adding a new entry to a heap?
Swap the new entry with the highest priority child node
Swap the new entry with the right child node
Swap the new entry with the left child node
Swap the new entry with the parent node
6.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
What is the first step in removing an entry from a heap?
Return the entry stored in the right child node
Return the entry stored in the highest priority child node
Return the entry stored in the root node
Return the entry stored in the left child node
7.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
What is the process called when reheapifying a heap upward?
Reheapification upward
Reheapification downward
Heapification upward
Heapification downward
Create a free account and access millions of resources
Similar Resources on Wayground
15 questions
Quiz 3 - 61_O

Quiz
•
University
10 questions
ADS live quiz

Quiz
•
University
15 questions
special exam in BINARY TREE

Quiz
•
University
16 questions
DS - Linked List - S1

Quiz
•
University
16 questions
Linked List and Arrays in JAVA

Quiz
•
University
15 questions
Knowledge Knockout[Quiz Round](2nd-4th years)

Quiz
•
University
20 questions
Node.js Server

Quiz
•
University
18 questions
CIS2303 Week 4_5 Ch_3

Quiz
•
University
Popular Resources on Wayground
10 questions
Video Games

Quiz
•
6th - 12th Grade
10 questions
Lab Safety Procedures and Guidelines

Interactive video
•
6th - 10th Grade
25 questions
Multiplication Facts

Quiz
•
5th Grade
10 questions
UPDATED FOREST Kindness 9-22

Lesson
•
9th - 12th Grade
22 questions
Adding Integers

Quiz
•
6th Grade
15 questions
Subtracting Integers

Quiz
•
7th Grade
20 questions
US Constitution Quiz

Quiz
•
11th Grade
10 questions
Exploring Digital Citizenship Essentials

Interactive video
•
6th - 10th Grade
Discover more resources for Computers
10 questions
Would you rather...

Quiz
•
KG - University
20 questions
Definite and Indefinite Articles in Spanish (Avancemos)

Quiz
•
8th Grade - University
7 questions
Force and Motion

Interactive video
•
4th Grade - University
10 questions
The Constitution, the Articles, and Federalism Crash Course US History

Interactive video
•
11th Grade - University
7 questions
Figurative Language: Idioms, Similes, and Metaphors

Interactive video
•
4th Grade - University
20 questions
Levels of Measurements

Quiz
•
11th Grade - University
16 questions
Water Modeling Activity

Lesson
•
11th Grade - University
10 questions
ACT English prep

Quiz
•
9th Grade - University