落選作 2 つめ。実行と連結が可能なバナーを生成するプログラムです。
/**/#/*@*/ include<stdio.h>/* @@@@*//**/
/**/char*r ,t[33301]="#ifnde" "f~x~"/**/
/**/"#inc" "l" "u" "d" "e~<s"/**/
/**/"td\\" "~" "i" "o" ".h>~"/**/
/**/"~#de" "f" "i" "n" "e~x("/**/
/**/"x)\\" "~" "p" "u" "t##~"/**/
/**/"char" "(" "x" ")" ";~in"/**/
/**/"t~ma" "i" "n" "(" "){~#"/**/
/**/"incl" "ude~" "_" "_FIL"/**/
/**/"E__~" "retu" "r" "n~0;"/**/
/**/"}~#u" "ndef"/**/
/**/"~x~#" "defi"/**/
/**/"ne~x" "(x)~"/**/
/**/"#~el" "se~x(~%04o" ")~#~"/**/
/**/"endi" "f~ROOq))U=" ">ggg"/**/
/**/"RHHg" "g" "]" "[rqk"/**/
/**/"brk1" "m" "d" "o4or"/**/
/**/"_]sf" "v" "Z" "fc>@"/**/
/**/"#e=4" "X" "D" "a;Hg"/**/
/**/"n)%|" "%" "X" "i)'|"/**/
/**/">8#'" "(" "4" ",IYk"/**/
/**/"@ca:" "4mM,N{$e|f" "gN6,"/**/
/**/"S.0_" "-Q,{Ii5K-8" "]8Xi"/**/
/**/"]8)u" "c^cu"/**/
/**/"'|]|" "'`Ci"/**/
/**/"`UaC" "oi#k"/**/
/**/"^jrf" "E/|L"/**/
/**/"a$l/" "lnl3"/**/
/**/"(M&0" "WS$(_S3w_5+{&6=E" "ZDy$"/**/
/**/"&gTo" "W(_$/9xn$+wso6//" "E(<#"/**/
/**/"miws" "Y" "003G"/**/
/**/"5=a|" "I" "+.i{"/**/
/**/"+;x9" "/" ";g%g"/**/
/**/"n$@g" "/" ":_4m"/**/
/**/"{6((" "E,GA**k>L1|))>G$" "J<(?"/**/
/**/"(B2y" ",?cwi'%kaqe]KiVk" "A%c]"/**/
/**/"1agD" "i]e$"/**/
/**/"ogTA" "=c;9"/**/
/**/"hVk'" "iY(<"/**/
/**/"$,J(" "sg'k"/**/
/**/"ucBe" "q[%?"/**/
/**/"+'8&" "P9n'o8o3y+'{4{'e" "%_Q]"/**/
/**/"=@$_" "Q%_Pq#",*s=t+148, *p,*q=/**/
/**/t+503, a[] ="kaf"/**/
/**/"c-&F" "#" "(:+'"/**/
/**/"1)gc" "{" "7g#e"/**/
/**/"%g'_" "m" "eik5"/**/
/**/"gn2C" "B2&.|gae*a$ke*mi" "'y6("/**/
/**/"a%y$" "#)%%0kn${$rrii_k" "k$-o"/**/
/**/"eao." "&y]a"/**/
/**/"k&nn" "i$$i"/**/
/**/"mmo&" "ee##"/**/
/**/"__$#" "ooaa"/**/
/**/"]#]]" ;int(F/**/
/**/)(char *f){return-sprintf (s,f,r/**/
/**/);}int main(){int(i)=0,x, y,c=0;/**/
/**/for(p= s,r =t; *(p )||++i/**/
/**/<57;(* r++ %=y =2* 63))*q/**/
/**/++=91- i-* p?* p++ :a[p+=/**/
/**/c,c=!c ,i* 2+c ];; for(;y/**/
/**/++>5+6 ?y= 0,c =getc(/**/
/**/stdin) ,r= t,c >=0:1;/**/
/**/printf ("%.3"/**/
/**/"9s",s ),r-=i/**/
/**/=10+F( "iocc"/**/
/**/"cioc" "*/%s"/**/
/**/"\n"), printf/**/
/**/(s-i-1 ,c))for(r-=F("%s/" "*ioc"/**/
/**/"ccio" )+8,x=1;x++<30;8[s +x]=2</**/
/**/x&&30> x&& (i- 7?i:42/**/
/**/)>>y/2 &1? 35: 32)i=p/**/
/**/[(c<32 ?0: -31 +c)*9+/**/
/**/x/3]%+ 93; ;;; return/**/
/**/0;/*!! !exec! !link! !!!!*//**/
/**/#/*x*/ define IOCCC( x)/**//**/
/**/;IOCCC (2015)/**/
/**/;IOCCC (2015)/**/
/**/}IOCCC (2015)/**/実行します。
$ gcc -o prog prog.c
$ echo -n Hello | ./prog
#ifndef/*i occcioc*/x
#include/* ioc*/<std\
io.h>/*ioc ################## iocccioc*/
#define/*i ################## ioc*/x(x)\
put##/*ioc ### */char(x);
int/*ioccc ### c*/main(){
#include/* ### */__FILE__
return/*io ### ccioc*/0;}
#undef/*io ################## occcioc*/x
#define/*i ################## cioc*/x(x)
#/*iocccio cioc*/else
x(/*ioccci ioc*/0110)
#/*iocccio ioc*/endif
#ifndef/*i occcioc*/x
#include/* ioc*/<std\
io.h>/*ioc ###### iocccioc*/
#define/*i ###### ioc*/x(x)\
put##/*ioc ###### ### */char(x);
int/*ioccc ###### ### c*/main(){
#include/* ### ###### */__FILE__
return/*io ### ###### ccioc*/0;}
#undef/*io ### ### occcioc*/x
#define/*i ### ### cioc*/x(x)
#/*iocccio cioc*/else
x(/*ioccci ioc*/0145)
#/*iocccio ioc*/endif
#ifndef/*i occcioc*/x
#include/* ioc*/<std\
io.h>/*ioc ### ### iocccioc*/
#define/*i ### ### ioc*/x(x)\
put##/*ioc ################## */char(x);
int/*ioccc ################## c*/main(){
#include/* ### */__FILE__
return/*io ### ccioc*/0;}
#undef/*io occcioc*/x
#define/*i cioc*/x(x)
#/*iocccio cioc*/else
x(/*ioccci ioc*/0154)
#/*iocccio ioc*/endif
#ifndef/*i occcioc*/x
#include/* ioc*/<std\
io.h>/*ioc ### ### iocccioc*/
#define/*i ### ### ioc*/x(x)\
put##/*ioc ################## */char(x);
int/*ioccc ################## c*/main(){
#include/* ### */__FILE__
return/*io ### ccioc*/0;}
#undef/*io occcioc*/x
#define/*i cioc*/x(x)
#/*iocccio cioc*/else
x(/*ioccci ioc*/0154)
#/*iocccio ioc*/endif
#ifndef/*i occcioc*/x
#include/* ioc*/<std\
io.h>/*ioc ###### iocccioc*/
#define/*i ###### ioc*/x(x)\
put##/*ioc ### ### */char(x);
int/*ioccc ### ### c*/main(){
#include/* ### ### */__FILE__
return/*io ### ### ccioc*/0;}
#undef/*io ###### occcioc*/x
#define/*i ###### cioc*/x(x)
#/*iocccio cioc*/else
x(/*ioccci ioc*/0157)
#/*iocccio ioc*/endifこの出力を実行すると、元の文字列が出てきます。つまり実行可能。
$ echo -n Hello | ./prog > hello.c $ gcc -o hello hello.c $ ./hello Hello
それから、このバナーは連結可能です。
$ echo ", world" | ./prog > world.c $ cat hello.c world.c > helloworld.c $ gcc -o helloworld helloworld.c $ ./helloworld Hello, world
以上。