lec0328-AVL - Announcements: MP5 available. Due 4/1,...

Info iconThis preview shows pages 1–6. Sign up to view the full content.

View Full Document Right Arrow Icon
Announcements: MP5 available. Due 4/1, 11:59p. Today: Balanced BST– Weiss, 4.4 What you should know from last time: • Operations exist that change structure of a BST - ____________. • These operations require ________ time. What you should not know from last time: • What to use them for. • How to use them. http://www.qmatica.com/DataStructures/Trees/BST.html
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
balanced trees - rotations 70 60 80 50 20 40
Background image of page 2
balanced trees - rotations 70 60 80 50 20 40
Background image of page 3

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Summary of rotation operations: 1. there are 4 kinds: left, right, left-right, right-left (symmetric!) 2. local operations (subtrees not affected) 3. constant time 4. BST characteristic maintained GOAL: use rotations to maintain balance of BSTs. height balanced trees - we have a special name: Three issues to consider as we move toward implementation: Rotating Maintaining height Detecting imbalance
Background image of page 4
8 4 6 5 9 12 10 3 1 11 2
Background image of page 5

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Image of page 6
This is the end of the preview. Sign up to access the rest of the document.

Page1 / 10

lec0328-AVL - Announcements: MP5 available. Due 4/1,...

This preview shows document pages 1 - 6. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online