Gray Code
Generate a sequence of `2^n` integers where each consecutive pair differs by exactly one bit in binary representation. The sequence starts at 0 and follows the Gray code ordering, where adjacent numbers have Hamming distance of 1.
Generate a sequence of `2^n` integers where each consecutive pair differs by exactly one bit in binary representation. The sequence starts at 0 and follows the Gray code ordering, where adjacent numbers have Hamming distance of 1.