
Episode 15 · Season 1
Episode 2.10 - Gray Code Conversion and Applications
About this episode
We continue our discussion of Gray code by presenting algorithms used to convert between the weighted numeral system of unsigned binary and the Gray code ordered sequence. We also show how to implement these algorithms in our code.
More from Geek Author
Digital data has many benefits, but what happens if it's in error? Moreover, how can we tell if a bit has been flipped? Our discussion begins with parity.
Having learned how to program bitwise operations, it is now time to flex our bit bashing muscles by investigating some creative ways to perform common programming functions.
Having learned how to program bitwise operations, it is now time to flex our bit bashing muscles by investigating some creative ways to perform common programming functions.
Inverting or flipping the bits of an integer is the third and last method of "bit bashing" we will discuss. There are two ways to invert bits: either flip all of them at once or use a mask to identify…
The ability to set bits may not seem important at first, but many algorithms in computing depend on just that. Join us as we control bits and build integers from scratch using the bitwise-OR.