Gray code: Difference between revisions

m
Line 2,046:
for i in 0 .. 32:
echo i, " => ", toBin(grayEncode(i), 6), " => ", grayDecode(grayEncode(i))</lang>
{{out}}
Output:
<pre>
0 => 000000 => 0
Anonymous user