Does what it says on the tin

There's "geeky" as in dull articles about needlessly complicated computery thingymajigs you might see around here, and then there's geeky that needs full on worshipping, like that of Mr Banks and his entry into the 1998 International Obfuscated C Code Contest.

Yep, this is a competition where one designs the worst-possibly coded, most-confusingly written, least intelligible - but still functioning - program in the computer language C with severe restrictions on code-length. In 1998 it was 1536 bytes. A byte, iPod kiddies, is 1/1073741824th of the size of a "gig". So Banks wrote a graphical flight simulator.

That is hilariously geeky enough as it is - to quote the author "if it weren't for the wonderful property of orthogonal matrices, this flight simulator would not have been possible." However he went one step further in his gaining of Poorhousian worship and wrote his program code to look like what it simulates. The main point of a flight sim is to let you fly an aeroplane around a bit, so of course the award-winning code had to look like a plane.

And it did. See below and kneel at the altar of raw unadulterated unreadable code-tastic talent.

					  double L ,o ,P
					 s[999],E,h= 8,I,
					1E3,r,t, u,v ,W,S=
					a,B,A=32.2,c, F,H;
					int N,q, C, y,p,U;
				       Window z; char f[52]
				    ; GC k; main(){ Display*e=
 XOpenDisplay( 0); z=RootWindow(e,0); for (XSetForeground(e,k=XCreateGC (e,z,0,0),BlackPixel(e,0))
; scanf("%lf%lf%lf",y +n,w+y, y+s)+1; y ++); XSelectInput(e,z= XCreateSimpleWindow(e,z,0,0,400,400,
0,0,WhitePixel(e,0) ),KeyPressMask); for(XMapWindow(e,z); ; T=sin(O)){ struct timeval G={ 0,dt*1e6}
; K= cos(j); N=1e4; M+= H*_; Z=D*K; F+=_*P; r=E*K; W=cos( O); m=K*W; H=K*T; O+=D*_*F/ K+d/K*E*_; B=
sin(j); a=B*T*D-E*W; XClearWindow(e,z); t=T*E+ D*B*W; j+=d*_*D-_*F*E; P=W*E*B-T*D; for (o+=(I=D*W+E
*T*B,E*d/K *B+v+B/K*F*D)*_; p K)N=1e4; else{ q=W/K *4E2+2e2; C= 2E2+4e2/ K
 *D; N-1E4&& XDrawLine(e ,z,k,N ,U,q,C); N=q; U=C; } ++p; } L+=_* (X*t +P*M+m*l); T=X*X+ l*l+M *M;
  XDrawString(e,z,k ,20,380,f,17); D=v/l*15; i+=(B *l-M*r -X*Z)*_; for(; XPending(e); u *=CS!=N){
				   XEvent z; XNextEvent(e ,&z;);
					 N-LT? UP-N?& E:&
					 J:& u: &h;); --*(
					 DN -N? N-DT ?N==
					 RT?&u;: & W:&h;:&J;
					  ); } m=15*F/l;
					  c+=(I=M/ l,l*H
					  +I*M+a*X)*_; H
					   )/S; K=F*M+(
					   h* 1e4/l-(T+
					   a=2.63 /l*d;
					   X+=( d*l-T/S
					    *(.19*E +a
					    )-M* v +A*
					    Z)*_; l +=
                                            K *_; W=d;
					    "%5d  %3d"
					    "%7d",p =l
			      O*57.3)%0550,(int)i); d+=T*(.45-14/l*
			     X-a*130-J* .14)*_/125e2+F*_*v; P=(T*(47
			     *I-m* 52+E*94 *D-t*.38+u*.21*E) /1e2+W*
			     179*v)/2312; select(p=0,0,0,0,&G;); v-=(
			       )/107e2)*_; D=cos(o); E=sin(o); } }


Post new comment

The content of this field is kept private and will not be shown publicly.
  • Allowed HTML tags: <a> <em> <strong> <cite> <code> <ul> <ol> <li> <dl> <dt> <dd> <blockquote> <del> <p>
  • Lines and paragraphs break automatically.
  • You may post code using <code>...</code> (generic) or <?php ... ?> (highlighted PHP) tags.
  • You may use [acidfree:xx] tags to display acidfree videos or images inline.
  • Images can be added to this post.

More information about formatting options

This question is for testing whether you are a human visitor and to prevent automated spam submissions.
2 + 3 =
Solve this simple math problem and enter the result. E.g. for 1+3, enter 4.