Here's a litle program I wrote to demonstrate your basic trig functions in C. See if you can guess what the trick is. Paste it into a file called halloween.c To compile it, use any "C" copiler, such as the free gcc:
gcc halloween.c -o halloween -lm
#include <math.h> main(i,r,c){ for(r=0;r<24;r++){ c=(int)(sinf(acosf(r/12.0-1))*24); if(r==23)printf("Happy Halloween");else for(i=0;i<24-c;i++)printf(" "); for(i=0;i<2*c;i++)printf("%c", ((r>4&&r<8&&(i>6&&i<12||i>26&&i<32))|| (r>12&&r<21&&i>7&&i<2*c-8))?' ':'@'); printf("\n");}}
Copyright (C) 2008 Henry Kroll III, www.thenerdshow.com
Copy and share but keep this notice intact.