Problem. The Chinese rings (Baguenaudier): rings on a bar. Ring can always be moved on or off; ring can be moved iff ring is on and rings are off. Remove all rings.

Answer: moves: The sequence of states visited is the reflected Gray code.

long long chineseRingsMoves(int n) { return (1LL << (n + 1)) / 3; }          // minimum moves to remove all n rings