摘要:
#define LeftChild(i)(2 * (i) + 1)void PercDown(int a[], int i, int n){ int c, t; for(t = a[i]; LeftChild(i) < n; i = c) { c = LeftChild(i); if(c != n - 1 && a[c + 1] > a[c]) c++; if(t < a[c]) a[i] = a[c]; else break; } a[i] ... 阅读全文
posted @ 2013-01-20 17:07
ChobitsSP
阅读(162)
评论(0)
推荐(0)
浙公网安备 33010602011771号