• 2021-04-14
    中国大学MOOC: 下面给出了霍夫曼编码问题的算法的伪代码,其中空白处应分别填入___ 输入:各字符频数http://edu-image.nosdn.127.net/_PhotoUploadUtils_b9f85b67-d6e2-439f-8365-6f2bb22a0ceb.png,字符数http://edu-image.nosdn.127.net/_PhotoUploadUtils_e35a832b-8bcc-4751-b43a-42abf1120256.png 输出:霍夫曼编码树//预处理将http://edu-image.nosdn.127.net/_PhotoUploadUtils_07a45d86-96fe-4806-9ca0-abd0edab1db5.png递增排序新建结点数组http://edu-image.nosdn.127.net/_PhotoUploadUtils_043bbf58-73d6-4789-992f-d3c5ee3b20b1.pngfor http://edu-image.nosdn.127.net/_PhotoUploadUtils_ad24654a-d306-4e05-8fce-c9e96e537312.png do http://edu-image.nosdn.127.net/_PhotoUploadUtils_db5be2f0-4bdb-426e-8032-aea2ac068bdb.png http://edu-image.nosdn.127.net/_PhotoUploadUtils_e38908ef-0597-48b4-b575-4381839ce440.png http://edu-image.nosdn.127.net/_PhotoUploadUtils_3b7b6925-0c80-46ab-80c1-8b2d328f9ba0.pngendhttp://edu-image.nosdn.127.net/_PhotoUploadUtils_e785bce9-af5a-4b54-8890-4ad70a5585af.pngfor http://edu-image.nosdn.127.net/_PhotoUploadUtils_4479436e-bfe2-4dce-a3d0-8e42044d9d2c.png do 新建结点http://edu-image.nosdn.127.net/_PhotoUploadUtils_97c23975-0b60-42c7-9a0a-cc059efc4615.png http://edu-image.nosdn.127.net/_PhotoUploadUtils_c00038d5-3c25-4965-93fa-bd2db198c1f8.png http://edu-image.nosdn.127.net/_PhotoUploadUtils_30842c3a-839a-4b9a-8fc9-5196655dc25b.png http://edu-image.nosdn.127.net/_PhotoUploadUtils_5aa683ee-d23d-4db5-b0cb-bb4805e6ca90.png http://edu-image.nosdn.127.net/_PhotoUploadUtils_908a0db0-e465-44cd-9bf3-c4a7ac9e552c.png http://edu-image.nosdn.127.net/_PhotoUploadUtils_dd0e0c1e-a285-4a20-abc6-256d3577f602.png endreturn http://edu-image.nosdn.127.net/_PhotoUploadUtils_5e644e79-2444-499b-9dfd-c0ee3ab22cb2.png