caylee
  • Member for 4 years, 6 months
  • Last seen more than a month ago
  • Kiel, Deutschland
Help! I forgot my password!
9 votes

C, 113 108 bytes f(int h){int i=47,j,k;while(++i<54)for(j=47;++j<54)for(k=47;++k<54;)if(h==i+j+j+k*3)printf("%c%c%c",i,j,k);} It is unique to see what is meant for output, the output is of ...

View answer
Output the PPCG Prime
4 votes

C, 519 427 414 396 377 bytes Thanks to Tas, Felix Palmen and Lynn. #define p(n,l)for(i=40*l;i;)putchar(--i%40?n+48:10); f(i){p(7,4)p(1,2)puts("188888888118888888811188888811188888811\...

View answer
Check If my String is Prime
1 votes

C, 113 bytes p(int c){for(int i=1;++i<c;)if(!(c%i))return 1;return 0;}c(char*s){char*a="p";while(*s++)if(p(*s))++a;printf(a);}

View answer
Randomly select a character, plinko-style
0 votes

C, 106 bytes int f(){int r=(int)random()%8;if(!r--)return 'A';if(--r-->0)if(r<2)return 'C';else return 'B';return 'D';}

View answer