POJ_3253_Fence Repair(哈夫曼树)
摘要:
1 # include 2 # include 3 int main() 4 { 5 int n,i,j,temp; 6 __int64 a[20000],sum=0,count=0,b; 7 scanf("%d",&n); 8 for(i=0;ia[j]&&j<n)16 {17 a[j-1]=a[j];18 j++;19 }20 a[j-1]=b;21 sum=sum+b;22 }23 printf("%I64d",sum);2... 阅读全文
posted @ 2013-08-19 11:16 随风浪子的博客 阅读(119) 评论(0) 推荐(0) 编辑