Hello I have a simple list that contains the follwing frequency table:

[file0]test 1,2,3.[file0]

[file1]
10 1
32 1
44 2
46 1
49 1
50 1
51 1
101 1
115 1
116 2
[/file1]

I wanted to write a simple huffman program that did not require ADT of any sort to create the table code for it and the output should be the following:

[out]
50 000
51 001
101 010
115 011
44 100
116 101
10 1100
32 1101
46 1110
49 1111
[/out]

It should be able to read from stdin and I was told that huffman encoding is simple enough that you didn't have to use advanced structures to generate it but so far I've only written the base program that just takes any file and calculates the freqency table and I'm on the part of genrating the huffman code.