winning selfprinter

utzoo!decvax!harpo!ihnp4!ihuxr!lew utzoo!decvax!harpo!ihnp4!ihuxr!lew
Fri Nov 19 00:57:09 AEST 1982


The winner of my proposed contest for the shortest C selfprinter that
would pass through cb was Philip Lantz (duke!ucf-cs!lantz). He sent
me the following:

main(){
	char*a="main(){%c%cchar*a=%c%s%c;%c%cprintf(a,10,9,34,a,34,10,9,10,10);%c}%c";
	printf(a,10,9,34,a,34,10,9,10,10);
}

As he pointed out, it is a straightforward extension of Steve Wagar's
one liner. I guess Steve will gag on that long line, though.

Lew Mammel, Jr. ihuxr!lew



More information about the Comp.lang.c mailing list