huffman.h
来自「哈夫曼编码器」· C头文件 代码 · 共 31 行
H
31 行
#include <string>
#include <iostream>
#include <conio.h>
#include <dos.h>
using namespace std;
class huffman
{
private:
typedef struct
{
char elem;
int weight,parent,lchild,rchild;
}hfnode,*hftree;
hftree hft;
int n;
bool selectmin(int m,int &lc,int &rc);
bool readdate();
bool readhfm(string filename);
bool writehfm(string filename);
public:
huffman();
bool creathuffmantree();
bool creathuffmantree(string filename);
~huffman();
bool encoding(string filename);
bool decoding(string filename);
};
bool fileprint(string filename);
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?