Skip to content

Latest commit

 

History

History
2 lines (2 loc) · 101 Bytes

File metadata and controls

2 lines (2 loc) · 101 Bytes

Gray Code

We can use bitwise to solve this problem, the Gray Code of i = i ^ (i / 2) = i ^ (i >> 1)