permutation date by not

f(a,b,c,d){for(d=b?0:printf("0%d\n",a);d++<(c%2?5-3/c:9);)b&(c-5||a%50<24)<<d&&f(a*10+d,b^1<<d,c+1);}main(){f(0,1022,0);}

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

download

return to the top page