Calculate the hamming distance of two hex strings or buffers