資料結構›Ch9 進階樹第 72 題/共 88 題
72. Optimal Binary Search Tree、OBST
#DS-09-072中Optimal Binary Search TreeOBST
(10%) Given a sequence of five distinct keys in sorted order (so that ) and six dummy keys representing values not in , we have a probability for and a probability for . Determine the cost of an optimal binary search tree for with the following probabilities:
| 0 | 1 | 2 | 3 | 4 | 5 | |
|---|---|---|---|---|---|---|
| 0.08 | 0.15 | 0.05 | 0.1 | 0.12 | ||
| 0.04 | 0.1 | 0.08 | 0.1 | 0.06 | 0.12 |
📄 成大111
▤完整推導請見《WH 資工筆記 · 資料結構》Ch9 進階樹