Gray code by *yuko*

y,u;main(k,o){for(o=~o%9;y<1<<o;y=k&-k)printf(--k?"\n%0*o":"Gray code  n=%d",o,u^=y*y*y);}

Note that non-ascii characters in the above source code will be escaped (such as \x9f).

download

return to the top page