Some minor optimizations
Optimized huffman