Twelve Days of Christmas by csanders

char*D[]={"first","second","third","four","fif","six","seven","eigh","nin","ten","eleven","twelf","Two turtle dove","Three French hen","Four calling bird","Five golden ring","Six geese a-lay","Seven swans a-swimm","Eight maids a-milk","Nine ladies danc","Ten lords a-leap","Eleven pipers pip","Twelve drummers drumm"};d;main(i){for(;d<12;printf("A%s partridge in a pear tree%c\n\n",d++?"nd a":"",d-11?46:33))for(printf("On the %s%s day of Christmas,\nmy true love sent to me\n",D[i=d],d>2?"th":"");i--;)printf("%s%s,\n",D[i+12],i>3?"ing":"s");}

Note that non-ascii characters in the above source code will be escaped (such as \x9f).

download

return to the top page