文件名称:hafuman
- 所属分类:
- 其他小程序
- 资源属性:
- [Windows] [Visual C] [源码]
- 上传时间:
- 2012-11-26
- 文件大小:
- 193kb
- 下载次数:
- 0次
- 提 供 者:
- we***
- 相关连接:
- 无
- 下载说明:
- 别用迅雷下载,失败请重下,重下不扣分!
介绍说明--下载内容均来自于网络,请自行研究使用
【问题描述】已知输入一串正整数,正整数之间用空格键分开,请建立一个哈夫曼树,以输入的数字为叶节点,求这棵哈夫曼树的带权路径长度。
【输入形式】首先输入正整数的个数,然后接下来为接下来的正整数,正整数个数不超过10个
【输出形式】输出相应的权值
【样例输入】5 4 5 6 7 8
【样例输出】69
-The length of the descr iption of the problem is known to enter a positive integer, a positive integer with a separate spacebar create a Huffman tree, digital input leaf node, find tree Huffman tree with the right path . Input form] First enter the number of positive integers, then the next for the next positive integer, is the integer number of not more than 10 [output in the form] output corresponding weights sample input] 545,678 【sample output】 69.
【输入形式】首先输入正整数的个数,然后接下来为接下来的正整数,正整数个数不超过10个
【输出形式】输出相应的权值
【样例输入】5 4 5 6 7 8
【样例输出】69
-The length of the descr iption of the problem is known to enter a positive integer, a positive integer with a separate spacebar create a Huffman tree, digital input leaf node, find tree Huffman tree with the right path . Input form] First enter the number of positive integers, then the next for the next positive integer, is the integer number of not more than 10 [output in the form] output corresponding weights sample input] 545,678 【sample output】 69.
(系统自动生成,下载前可以参看下载内容)
下载文件列表
0303
....\0303.c
....\0303.dsp
....\0303.dsw
....\0303.ncb
....\0303.opt
....\0303.plg
....\Debug
....\.....\0303.exe
....\.....\0303.ilk
....\.....\0303.obj
....\.....\0303.pch
....\.....\0303.pdb
....\.....\vc60.idb
....\.....\vc60.pdb