Adding hamming distance. Also cleaned up development testing code