correctly compute hamming for strands of unequal length