Gray code by 51b

import std.stdio;void main(){int m,n;for(write("Gray code  n=",n=getchar%8);m<1<<n;)writef("
%0*b",n,m++^m/2);}

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

download

return to the top page