Download presentation
Presentation is loading. Please wait.
Published byEustace Bishop Modified over 9 years ago
1
Data Structure II
2
Outline Heap Binary Search Tree Hash Table Binary Indexed Tree Segment Tree
3
Heap A left-complete binary tree which has every node greater than its two children, if any of them exists Insert Extract-max Heapify Make-heap
4
Binary Search Tree A binary tree which exhibits the following properties ◦Root > all elements in left subtree ◦Root <= all elements in right subtree Search ◦Most convenient if written recursively Insert – a bit trivial Delete ◦0 children, 1 child, 2 children Balance Tree ◦AVL tree, Red-Black Tree
5
Hash Table “Dictionary” Search – O(1) Insert – O(1) Delete – O(1) Collision? Hash function Close Addressing ◦Chaining Open Addressing
6
Binary Indexed Tree Peter Fenwick http://eprints.kfupm.edu.sa/19492/1/194 92.pdf
7
Segment Tree http://ttts.tust.edu.cn/UpFile/UpAttachme nt/2008-5/20085292039.doc http://ttts.tust.edu.cn/UpFile/UpAttachme nt/2008-5/20085292039.doc
8
Thank you! Dinner Time…
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.