International Obfuscated C Codes Contest

The International Obfuscated C Codes Contest (in French, international contest of code C obscure) is a contest of programming organized each year since 1984 (except for 1997, 1999, 2002 and 2003). There are several gaining entries each year, and each year returns in a category of the kind: “Greater abuse the preprocessor C” or “the most incoherent Behavior”.

The IOCCC were launched by Landon Curt Noll and Larry Bassel. They were speaking about the abominable code of which they were to make maintenance in their daily work. They then decided to organize a contest of the worst code C possible. In the authorized space of only a few KB, the participants succeed in making complicated things: the winner of 2004 proved to be an operating system.

Some quotations of the winners of 2004 include:

  • to simplify the things, I avoided the preprocessor C and the complicated instructions like “yew”, “for”, “C”, “while”, “switch”, and “goto”.
  • We are not still sure to have a useful program, but it is the first atomic fission seen on the IOCCC.
  • the program implements an ALUMINUM of 11 bits in the preprocessor.
  • I realized that to calculate the prime numbers up to 1024 fact of including the program itself more than 6,8 million times.

An example of entry is:

#define _ - F<00||--F-OO--; int F=00, OO=00; hand () {F_OO (); printf (" %1.3f \ n" , 4.*-F/OO/OO);}F_OO () { _-_-_-_ _-_-_-_-_-_-_-_-_ _-_-_-_-_-_-_-_-_-_-_-_ _-_-_-_-_-_-_-_-_-_-_-_-_-_ _-_-_-_-_-_-_-_-_-_-_-_-_-_-_ _-_-_-_-_-_-_-_-_-_-_-_-_-_-_ _-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_ _-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_ _-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_ _-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_ _-_-_-_-_-_-_-_-_-_-_-_-_-_-_ _-_-_-_-_-_-_-_-_-_-_-_-_-_-_ _-_-_-_-_-_-_-_-_-_-_-_-_-_ _-_-_-_-_-_-_-_-_-_-_-_ _-_-_-_-_-_-_-_ _-_-_-_ }

This program calculates pi by looking at its own surface; a more precise value can be obtained by using a larger program.

Some remarkable aspects of the entries include:

  • the shape of the listing, which can resemble images, text, etc
  • Of the redefinitions of the preprocessor to make the code harder to read.
  • Of the car-modifying code.
  • the worst abuse the rules: on several occasions, an entry was subjected which was so obviously absurd that it involved a redefinition of the rules for the years to come. This is, obviously, very an great honor. An example is more the little program which posts itself. The entry was a program of size zero, which, when it was launched, posted zero bytes with the screen (that requires a creative use of the makefile to fall right).

Several of the preceding entries are notable to cause some dreadful crash landings of compilers (more particularly Visual Studio).

Internal bond

External bond

  • the Web site of the IOCCC

Random links:Conger | FK Spartak Naltchik | Enuma Elish | Christian Daudel | Earl Hebner | Comté_de_Carleton,_Nouveau_Brunswick