Joshephus or MamakoDate Sequence EASY by 301

main(y,e,a,h){for(;~scanf("%d%d",&y,&e);)for(a=0;a<y;printf("%d%c",h,a<y?32:10))for(h=e*++a;h>y;h/=e-1)h=e*(h-y)-1;}

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

download

return to the top page