Problem 1611 · Hard
The minimum count is the XOR of all right shifts of n, which is the inverse Gray code of n.
Open the interactive visualisation