changed behaviour of hamming distance for strings of unequal length