11 - AVL Trees

11 - AVL Trees

University

9 Qs

quiz-placeholder

Similar activities

red black tree data structure

red black tree data structure

University

10 Qs

Quiz despre B Tree

Quiz despre B Tree

University

10 Qs

Trees

Trees

University

10 Qs

Data Structure and Algorithms Semi-Final Examination

Data Structure and Algorithms Semi-Final Examination

University

13 Qs

BCSC0006 Trees

BCSC0006 Trees

University

10 Qs

Quiz Red-Black Tree

Quiz Red-Black Tree

University

14 Qs

Quiz Champ Level 3

Quiz Champ Level 3

University

10 Qs

rbtq

rbtq

University

5 Qs

11 - AVL Trees

11 - AVL Trees

Assessment

Quiz

Computers

University

Hard

Created by

Jason King

Used 73+ times

FREE Resource

9 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

20 sec • 1 pt

When performing trinode restructuring in an AVL tree, which node should be labeled "Z"?
the first node at which the height-balance property is violated
the first node that would be visited in an inorder traversal
the child of the node where the height-balance property is violated
the traller grandchild of the node at which the height-balance property is violated

2.

MULTIPLE CHOICE QUESTION

20 sec • 1 pt

The goal of trinode restructuring is to ___.
balance the subtree
move "a" to be the root
move "c" to be the root
move "y" to be the root

3.

MULTIPLE CHOICE QUESTION

20 sec • 1 pt

In an AVL tree, for every internal node p, the heights of the children of the node p ______.
differ by at most 1
differ by at most 2
must be equal
must be different

4.

MULTIPLE CHOICE QUESTION

20 sec • 1 pt

Media Image

Is the following tree an AVL tree?

no

yes

5.

MULTIPLE CHOICE QUESTION

20 sec • 1 pt

Media Image

Is the following tree an AVL tree?

yes

no

6.

MULTIPLE CHOICE QUESTION

20 sec • 1 pt

Media Image

Assume we deleted the left child of 10 (now replaced with a sentinel node in the tree below). What node should be labeled "Z"?

10

12

15

20

7.

MULTIPLE CHOICE QUESTION

20 sec • 1 pt

Media Image

Assume we deleted the left child of 10 (now replaced with a sentinel node in the tree below). What node should be labeled "Y"?

15

10

12

20

8.

MULTIPLE CHOICE QUESTION

20 sec • 1 pt

Media Image

Assume we deleted the left child of 10 (now replaced with a sentinel node in the tree below). What node should be labeled "X"?

20

10

12

sentinel

9.

MULTIPLE CHOICE QUESTION

20 sec • 1 pt

What is the worst-case height of an AVL tree?
O(log n)
O(n)
O(n logn)
O(1)