Given two non-negative integers x and y, return the Hamming distance between them.
The Hamming distance is the number of bit positions where the corresponding bits of the two integers differ.
For example, 1 (001) and 4 (100) differ in 2 positions.
x = 1, y = 42x = 3, y = 11x = 0, y = 000 <= x, y <= 2^31 - 1Run your code to see results
Use Cmd+Enter to run