[問題] heapify worst case
我看Introduction to algorithms
在分析MAX-heapify T(n) = T(2n/3) + O(1)
有一句話是這樣說的
the children's subtrees each have size at most 2n/3
the worst case occurs when the last level of the tree is exactly half full
我是想問 2n/3是如何求得的?
那本書那一段話怎麼看我都看不懂@@
謝謝了..
--
※ 發信站: 批踢踢實業坊(ptt.cc)
◆ From: 140.123.104.24
※ 編輯: k1006boy 來自: 140.123.104.24 (10/05 12:45)
※ 編輯: k1006boy 來自: 140.123.104.24 (10/05 12:47)
※ 編輯: k1006boy 來自: 140.123.104.24 (10/05 12:47)
→
10/05 12:48, , 1F
10/05 12:48, 1F
推
10/05 19:45, , 2F
10/05 19:45, 2F
→
10/05 19:46, , 3F
10/05 19:46, 3F
→
10/05 19:49, , 4F
10/05 19:49, 4F
→
10/05 19:49, , 5F
10/05 19:49, 5F