怡然月饼

文章
3
资源
0
加入时间
2年10月24天

ZOJ 3963 Heap Partition(贪心)

A sequence S={s1,s2,...,sn}S = \{s_1, s_2, ..., s_n\} is called heapable if there exists a binary tree T with n nodes such that every node is labelled with exactly one element from the sequence S, and