Tuesday, 19 August 2008

Closed for new entries

No new entries now.

The judges have started awarding points; expect the results soon.

Tuesday, 12 August 2008

Deadline change

I'm very happy with how well the Self-Documenting Code Contest has been recieved. Lots of people have written to comment on how interesting the challenge was, and we've had 34 programs submitted so far, more than double my original wild guess.

I only have one problem: that 1st of September deadline. I basically picked it arbitrarily, as a nice round number, but now it's really looking a very long way away. The number of submissions have dropped to a trickle now; it seems unlikely that anyone is really going to need that much time to finish. And most important: I want to get onto scoring them! I'm bored!

Sure, I could probably get more coming in if I submitted the contest to more websites, but I don't really see a need to. 34 is plenty. So I've decided to cut things short: you now have until Monday the 18th of August to submit your programs.

If you're still planning to submit an entry: what are you waiting for?

Monday, 4 August 2008

Announcing the Self-Documenting Code Contest

Programs must be written for people to read, and only incidentally for machines to execute.

-- Abelson & Sussman, Structure and Interpretation of Computer Programs

The Obfuscated C contest has always annoyed me.

If programs are for communicating with other programmers, why do we have a contest that encourages such complete perversions of best practises? (Ok, that's really a rhetorical question - I know perfectly well how much fun it can be to put hours of work into one devious, unreadable block of line-noise.)

But then I thought... someone should make another competition. One that encourages the opposite - learning to make
better code. A competition in which points are awarded for code that's simple, easy to read, more straightforward.

And here we are. As of today, Monday the 4th of August 2008, The Self-Documenting Code Contest (SDCC) is now officially open. I will be accepting submissions all month, until Monday the 1st of September.
EDIT: Correction - I will be accepting submissions until Monday the 18th of August.

The rules:

This contest is about self-documenting
code. In other words, your goal is to write a program whose logic is so obvious, it is its own documentation.
You may not use comments in your program. Nor may you emulate comments by using a purely decorative string value, or a paragraph-long identifier, etc.

2) Any language.
You may use any programming language - but you might want to bear in mind that if a judge is familiar with your chosen language, s/he will probably find it easier to read.

Currently the panel consists of 5 judges, coming from a wide range of programming backgrounds - academic, game programming, web programming, etc... and just to mix it up, my wife, who has no programming experience.

The judges have one thing in common: their knowledge of English. So ideally, that's your target: a program that can be understood by anyone who speaks English.

Unrealistic? Perhaps. But those are the rules everyone is working under.

Your objective:
Write a program that generates all two-word anagrams of the string "documenting". Here's a word list you might want to use: http://pragdave.pragprog.com/data/wordlist.txt.

When you're done, send the results to selfdocumenting@hotmail.com.

Good luck!
Laurie Cheers