Enable Javascript in your browser and then refresh this page, for a much enhanced experience.
2-liner: itertools.zip_longest solution in Creative category for The Hamming Distance by Stensen
from itertools import zip_longest as zip
checkio = lambda a, b: sum(1 for i, j in zip(bin(a)[2:][::-1], bin(b)[2:][::-1], fillvalue='0') if i != j)
Oct. 29, 2020