Insert the following numbers into a binary search tree in order: 9, 20, 7, 8, 10, 22, 21. Where will the number 10 be located?

Midterm Review

Flashcard
•
Engineering
•
University
•
Hard
Quizizz Content
FREE Resource
Student preview

25 questions
Show all answers
1.
FLASHCARD QUESTION
Front
Back
As the right child of 8.
2.
FLASHCARD QUESTION
Front
Insert the numbers 15, 10, 20, 5, 12, 17, 25 into a BST. What is the in-order traversal of the tree?
Back
5, 10, 12, 15, 17, 20, 25
3.
FLASHCARD QUESTION
Front
What is the time complexity of merge sort?
Back
O(nlogn)
4.
FLASHCARD QUESTION
Front
Which of the following correctly describes a stack and a queue?
Stack: Last In, First Out (LIFO);
Queue: First In, First Out (FIFO).
Back
Stack: Last In, First Out (LIFO);
Queue: First In, First Out (FIFO).
5.
FLASHCARD QUESTION
Front
Write a recursive method to count the total number of leaf nodes in a binary tree. What is the base case for this recursive function?
Back
When the node has no children.
6.
FLASHCARD QUESTION
Front
What is the height of the following binary tree?
10
/ \
5 15
/ \
3 7
Back
3
7.
FLASHCARD QUESTION
Front
Which of the following is true for a binary search tree (BST)?
Options:
All left children are greater than the parent node.
All right children are smaller than the parent node.
All left children are smaller and all right children are greater than the parent node.
It is not necessary for a BST to have ordered nodes.
Back
All left children are smaller and all right children are greater than the parent node.
Create a free account and access millions of resources
Similar Resources on Quizizz
15 questions
Appropriate Rejection Region for a Given Level of Significance

Flashcard
•
University
15 questions
1342 - Final Review Questions - Test #4

Flashcard
•
University
20 questions
Aspire Vocab Review

Flashcard
•
KG
20 questions
Linked List

Flashcard
•
Professional Development
24 questions
PSUEDOCODE 2 CAPGEMINI

Flashcard
•
Professional Development
23 questions
Comp 210 MT2 Review

Flashcard
•
University
15 questions
1342 - Final Review Questions - Test #4

Flashcard
•
University
20 questions
EKG TERMINOLOGY

Flashcard
•
Professional Development
Popular Resources on Quizizz
10 questions
Chains by Laurie Halse Anderson Chapters 1-3 Quiz

Quiz
•
6th Grade
20 questions
math review

Quiz
•
4th Grade
15 questions
Character Analysis

Quiz
•
4th Grade
12 questions
Multiplying Fractions

Quiz
•
6th Grade
30 questions
Biology Regents Review #1

Quiz
•
9th Grade
20 questions
Reading Comprehension

Quiz
•
5th Grade
20 questions
Types of Credit

Quiz
•
9th - 12th Grade
50 questions
Biology Regents Review: Structure & Function

Quiz
•
9th - 12th Grade
Discover more resources for Engineering
10 questions
Identifying equations

Quiz
•
KG - University
16 questions
Chapter 8 - Getting Along with your Supervisor

Quiz
•
3rd Grade - Professio...
6 questions
Railroad Operations and Classifications Quiz

Quiz
•
University
71 questions
Logos

Quiz
•
3rd Grade - University
8 questions
Mali - Geography

Quiz
•
University