Slashdot Mirror


IOCCC Winners Announced

Arachn1d writes "The IOCCC has finally announced the winners of the 2004 contest.
With winners this year including a mini-OS and a ray-tracer, the submissions should be interesting indeed - if you can make sense of them. According to the page, the actual code for the winners should be up mid-october."

61 of 175 comments (clear)

  1. Obfuscation by BoldAC · · Score: 5, Informative

    For those who don't know what this is all about...

    It's all about how to obfuscate baby!

    1. Re:Obfuscation by Anonymous Coward · · Score: 5, Interesting
    2. Re:Obfuscation by Davak · · Score: 3, Informative
    3. Re: Obfuscation by Black+Parrot · · Score: 2, Funny


      > For those who don't know what this is all about...

      Darn. I clicked it in hopes of seeing pix from the International Olympic Committee Contortionist Competition.

      > It's all about how to obfuscate baby!

      Was the article text one of the contest entries?

      --
      Sheesh, evil *and* a jerk. -- Jade
    4. Re:Obfuscation by h4rm0ny · · Score: 3, Informative


      How to obfuscate in copious detail.

      How to write unmaintainable code

      --

      Aide-toi, le Ciel t'aidera - Jeanne D'Arc.
    5. Re:Obfuscation by revividus · · Score: 2, Funny

      But I wanted a link to "How to write intelligible code in Perl..." Caveat: I like perl. :-)

  2. Umm by stratjakt · · Score: 3, Interesting

    Who's the IOCCC and what was this contest about? Some programming thing obviously. Is this that obfuscated perl thing?

    Seriously, a sentence or two of information in the submissions doesn't hurt.

    --
    I don't need no instructions to know how to rock!!!!
    1. Re:Umm by TheShadowHawk · · Score: 5, Funny

      Maybe that's the whole point. Everything (including the article) is well... obfuscated.

      --
      Friends don't let Friends use Internet Explorer.
    2. Re:Umm by ophix · · Score: 5, Funny

      wouldnt it need to be an UNobfuscated perl code contest? ;}

    3. Re:Umm by skribble · · Score: 2, Funny

      Apparently even the web site is obfuscated now.

      --
      --- Nothing To See Here ---
  3. Windows CE? by wackysootroom · · Score: 4, Funny

    Was the Mini-Os Windows CE by any chance? I'd bet that's pretty obfuscated!

  4. Much better than the last 2 years by dtfinch · · Score: 3, Insightful

    When there was no contest at all. "Yeah, everyone send in your entries. Oh, nevermind, maybe next year."

    Of course it looks like those extra 2 years paid off. This year's winners look very interesting.

  5. If the IOCCC is like the IOC by Omega1045 · · Score: 5, Funny

    If the IOCCC is anything like the IOC, I am sure they will ask some of the winners to give back their prizes because of judging mistakes, and probably screwed over several Russian participants.

    --

    Great ideas often receive violent opposition from mediocre minds. - Albert Einstein

  6. Let me be the first to say... by GillBates0 · · Score: 3, Funny
    10333 r0x0rzz. 0bf534710n rul3zz!

    C0N6R47UL4710N5 W1NN3RZZ!

    --
    An Indian-American Hindu committed to non-violent thought/speech/action alarmed by the global explosion of radical Islam
    1. Re:Let me be the first to say... by Short+Circuit · · Score: 2, Funny

      What's really, really scary, is that I could read that just fine...

  7. I can smell the smoke from here... by pedestrian+crossing · · Score: 4, Informative

    Since the summary isn't very informative, and the servers are rapidly slowing down, it is the International Obsfucated C Code Contest. About all that is (was?) on their page is the list of winners...

    --
    A house divided against itself cannot stand.
  8. Additional Mirror by pikine · · Score: 5, Informative

    us1 mirror and see Google cache for more.

    --
    I once had a signature.
  9. Site content by houghi · · Score: 5, Informative

    Not much. No source code yet. Here is the content of the site:

    Here are the names and categories for the winners of the 17th IOCCC. The source code has not been released yet. The winners have been notified by EMail. They will be given a chance to review the write-up of their entry. Once this process is complete the source code will be made available on the winning entries web page. We anticipate that this will be in mid-October.

    The winners are,

    * Best of Show

    Gavin Barraclough - Mini-OS
    Manchester, UK

    screenshot

    * Best One-Liner

    Eryk Kopczynski - OCR of 8, 9, 10 and 11
    Warszawa, Poland

    * Best Utility

    Don Yang - A CRC inserter
    Covina, California, USA

    * Best Non-Use of Curses

    Mark Schnitzius - Editor animation
    Singapore

    * Best X11 Game

    Daniel Vik - X Windows car racing game
    La Jolla, California, USA

    screenshot

    * Best use of "Precious" Lines

    Anonymous - Rendering of a stroked font
    Singapore

    screenshot

    * Best Abuse of CPP

    Daniel Vik - Calculates prime numbers using only CPP
    La Jolla, California, USA

    * Best Calculated Risk

    Brent Burley - A Poker game
    Burbank, California, USA

    * Best use of Vision

    Nick Johnson - Curses maze displayer/navigator with only line-of-sight visibility
    Christchurch, New Zealand

    * Best Font Engine

    Jeff Newbern - Renders arbitary bitmapped fonts
    Springwood, Queensland, Australia

    * Most Functional Output

    Jonathan Hoyle - Curses based polynomial graphing with auto-scale
    Ann Arbor, Michigan, USA

    * Best use of Light and Spheres

    Anders Gavare - A ray tracer
    Gothenburg, Sweden

    screenshot

    * Best Abuse of Indentation

    Stephen Sykes - Space/tab/linefeed steganography
    Helsinki, Finland

    * Best Abuse of the Guidelines

    Anthony Howe - A CGI capable HTTP server
    Cannes, France

    * Best Abuse of the Periodic Table

    John Dalbec - Conway's look'n'say sequence split into elements
    Canfield, Ohio, USA

    --
    Don't fight for your country, if your country does not fight for you.
  10. Mirrors by lachlan76 · · Score: 5, Informative

    Before it all goes down, here are the mirrors:

    Asia
    * http://www.tw.ioccc.org/ - Hsin-Chu, Taiwan (24 48' N 120 59' E)

    * Australia and other Pacific http://www.au.ioccc.org/ - Sydney, Australia (34 0' S 151 0' E)

    Europe
    * http://www.de.ioccc.org/ - Hamburg, Germany (53 33' N 10 2' E)
    * http://www.es.ioccc.org/ - Madrid, Spain (40 25' N 3 41' W)
    * http://www.gr.ioccc.org/ - Athens, Greece (38 00' N 23 44' E)
    * North America www0.us.ioccc.org - Sunnyvale California, US (37 22' N 122 02' W)
    * www1.us.ioccc.org - Saint Paul, Minnesota US (44 57' N 93 06' W)

  11. Time to turn in your geek card... by GillBates0 · · Score: 4, Funny
    Every self respecting geek knows what the IOCCC is. By admitting that you don't, you've demonstrated your inability to cope with the rigorous demands of abiding by the high standards of geekiness.

    Please hand in your Geek membership card on your way out. Thank you.

    --
    An Indian-American Hindu committed to non-violent thought/speech/action alarmed by the global explosion of radical Islam
    1. Re:Time to turn in your geek card... by lachlan76 · · Score: 4, Insightful

      Not only that, I don't consider the ability to churn out unreadable code a good trait in a programmer

      To be able to make something like that, you need to be able to understand the language well, which is a good thing.

    2. Re:Time to turn in your geek card... by Emil+Brink · · Score: 5, Insightful

      Whoa there, turn up the humour and creativity-appreciation knobs a couple of notches please. I don't think anyone likes to see obfuscated code in production environments, but if you haven't read any IOCCC entries, you should. They can be real eye-openers when it comes to realizing what you can do with the C language (and preprocessor) when put in the right hands. Plus, it's just plain fun! :)

      --
      main(O){10<putchar(4^--O?77-(15&5128 >>4*O):10)&&main(2+O);}
    3. Re:Time to turn in your geek card... by Anonymous Coward · · Score: 4, Insightful

      As I understand it, this contest is basically "who can turn out the shittiest code that still runs?"

      (1) It's for fun.
      (2) It's a famous tradition.
      (3) There is a great elegance in the entries which win; they are far from shitty.
      (4) Chill out.

    4. Re:Time to turn in your geek card... by torpor · · Score: 2, Informative

      Not only that, I don't consider the ability to churn out unreadable code a good trait in a programmer. Nothing geeky about it, just sloppy.

      i consider the ability to at least appreciate unreadable code, and have a good time with it, for fun, just coz, to be a good trait in a programmer. and thats what this IOCC thing is. for fun.

      (thus you're fired! hand in your geekcard on the way out...)

      --
      ; -- the corruption of government starts with its secrets. a truly free people keep no secrets. --
    5. Re:Time to turn in your geek card... by stratjakt · · Score: 4, Funny

      Here's an example of what I'm talking about:

      I got a resume from some kid just out of University. He attached some samples of the code he wrote. One of them was the perennial "calendar" app that I think we all were tasked to write.

      Anyhow, I was perusing the code. It was pretty sloppy, one-letter variable names, multiple statements crammed together on single lines.

      So I get to this one section of code. I can't even remember how it worked now, but it was this convoluded for() statement that flipped a flag and did some weird ass computation. It took me about 10 minutes of "stepping through" it in my head to figure out what it was doing.

      It was calculating leap-years. I actually stared at it in shock, imagining how much time and energy this kid spent figuring out the worlds most assinine way to figure out if it's leapyear. I would have just wrote "if (year%4 == 0) { days_in_feb=29; }" or something of the sort. I wouldnt write "if (!(year%4)) {};" because perfoming boolean tests on integers is another pet peeve, it doesn't improve the code, just detracts slightly from its readability.

      I actually interviewed the kid, and pointed the lines out to him. I asked him why he didn't just use the modulus operator. He just stared at me blankly. He had no clue what "modulus" meant.

      As creative as his "solution" was, his code was bad, and he was a shitty programmer with a very very poor understanding of the language.

      It's all cool to have this contest, and if that's how people want to spend their spare time, go ahead. I'm just trying to send a message to the newbies reading slashdot who are still in school and tend to think this is a hallmark of a good coder in the "real world". In the real world or business, anything that makes your day more of a hassle than it needs to be, is a bad thing.

      Leave the obfuscation to the marketing department. We have one who actually listed double-ROT13 encryption as a "feature" of our product. Ok, he asked me what encryption we supported by default, and I told him double-ROT13 not realizing just how dense he was. The story gets better! The marketing shpiel he put together was going to the IT security folks at the NSA! One of them called me up, in tears from laughing. He asked if I could implement quad-ROT13. I told him I could implement 2^n-ROT13, iff n>0.

      But that's another story for another article.

      --
      I don't need no instructions to know how to rock!!!!
    6. Re:Time to turn in your geek card... by UserGoogol · · Score: 3, Informative

      The IOCCC is a sort of piece of classic Hacker culture. That is to say, doing something difficult and mildly amusing just because you can. Also, to make fun of C for having such a ridiculous syntax as compared to sensible languages like Lisp. (Although by this day and age we've all grown up and seen Perl, so we don't care about that as much.)

      Anyway, this is not merely "bad code," in the sense that an idiot might program this stuff. This is the sort of code you can only attain when you actively aim for it. You really need to know the language well to know how to fuck with it so thoroughly.

      --
      "Never attribute to malice that which can be adequately explained by stupidity." -- Hanlon's Razor
    7. Re:Time to turn in your geek card... by Bastian · · Score: 3, Insightful

      Depending on where I'm applying, I would put winning the IOCCC on my resume. If you are looking at an employer who would know what it is, it shows that you have more knowledge of how computers and (at least) the C programming language work than most people. It doesn't show that you always turn out crappy code - those in the know also know that the IOCCC got its start with a bunch of skilled programmers ridiculing people who turn out crappy code.

      If they don't know, hey, it says you won a fairly well-known programming contenst.

    8. Re:Time to turn in your geek card... by ComaVN · · Score: 4, Insightful

      Leave the obfuscation to the marketing department. We have one who actually listed double-ROT13 encryption as a "feature" of our product. Ok, he asked me what encryption we supported by default, and I told him double-ROT13 not realizing just how dense he was. The story gets better! The marketing shpiel he put together was going to the IT security folks at the NSA! One of them called me up, in tears from laughing. He asked if I could implement quad-ROT13. I told him I could implement 2^n-ROT13, iff n>0.

      Actually, I think you're the one who's dense, when you think someone from marketing who asks you a straightforward question about your product is supposed to understand a geek-joke.

      It's not his job to check or even understand all the technical info. It's (presumably) yours.

      --
      Be wary of any facts that confirm your opinion.
    9. Re:Time to turn in your geek card... by MORTAR_COMBAT! · · Score: 2, Informative
      It was calculating leap-years. I actually stared at it in shock, imagining how much time and energy this kid spent figuring out the worlds most assinine way to figure out if it's leapyear. I would have just wrote "if (year%4 == 0) { days_in_feb=29; }" or something of the sort.

      determining a leap year is more than just having it be divisible evenly by 4: The Gregorian calendar adds an extra day to February, making it 29 days long, in years divisible by 4, excepting years divisible by 100, but including years divisible by 400. So 1996, 2000, and 2400 are leap years but 1899, 1900 and 2100 are not.

      So following the literal description, in Java one might write:
      int iDaysInFeb_ = ( 0 != iYear_ % 4 ) ? 28
      : ( 0 != iYear_ % 100 ) ? 29
      : ( 0 != iYear_ % 400 ) ? 28
      : 29;
      Probably there are better and more optimized paths than this... but hey, at least I checked to make sure it compiled and worked :)
      --
      MORTAR COMBAT!
    10. Re:Time to turn in your geek card... by MORTAR_COMBAT! · · Score: 2, Informative

      your implemetation begs the question: is it better to perform 3 division and 3 addition operations, or simply 3 division and 3 comparison operations?

      on my PC it turned out that it takes twice as long to go the route of strange addition ;]

      --
      MORTAR COMBAT!
  12. Funny, but sickening by Anonymous Coward · · Score: 5, Insightful

    I always though this contest was funny, but in a dark and sinister way. I can't tell you how many times I've looked at someone else's code and spent hours trying to figure it out. In the real world, it's not funny.
    I'm amazed at how someone can acheive such obfuscated code without really trying.

    1. Re:Funny, but sickening by Ignignot · · Score: 2, Insightful

      I'm amazed at how someone can acheive such obfuscated code without really trying.

      I'm not amazed at all - I pay special attention to my code so that someone else could come in and use it. That doesn't mean they'll be able to just step in and understand everything, it'll be hard no matter what. But if I didn't try, I think everything I made would be unusable by anyone else. In my mind that makes the code worth very little - it is the ability to reuse code that makes it valuable. I've debugged or added features to other people's programs (once in VB / Access, [shudder]) and it can be a nightmare even with comments. I think that most of the time people get into a coding zone and they're able to just chug through 100 lines or more at once, holding the entire program in their head for awhile. The problem is, if you do that you usually don't comment well (if at all). I try to proofread everything I write, putting comments back in, but for most people it isn't worth the effort. "It compiles, runs correctly, I'm done! Time to surf slashdot!"

      --
      I submitted this story last night, and it didn't get posted.
    2. Re:Funny, but sickening by Anonymous Coward · · Score: 3, Insightful

      Somebody mod this prick down, he's in desperate need of a sense of humour.

      The whole point of the IOCCC is to demonstrate how ridiculously unreadable C programs can get if you really try. And if you don't think writing a raytracer or whatever within the guidelines set in the competition rules is worthy of admiration then you've never picked up a C compiler in your life.

      I see you have a job that requires you to read CVs and presumably hire people. Please tell us which company this is so we can avoid this miserable establishment.

    3. Re:Funny, but sickening by micromoog · · Score: 2, Insightful

      People do this for fun. This has nothing to do with productivity, the bottom line, or actualizing organizational synergy.

    4. Re:Funny, but sickening by groomed · · Score: 4, Insightful

      Yes, I suppose, but what does any of that have to do with the IOCCC?

      It's just a competition, and like most competitions, the results are fairly pointless outside the intended domain.

      Reading your rant is like watching a spectator in the Tour de France yell "learn how to drive a car you idiot!" at Lance Armstrong.

    5. Re:Funny, but sickening by Urkki · · Score: 4, Insightful
      • With recursion you get 20 function calls with all their associated overhead. A for loop is a much better solution.

      Except a properly written recursive function, and a loop end up being exactly the same thing once compiled... Even with a C compiler

      Of course anybody putting purposefully obfuscated code into any real software should be shot... All the unpurposefully obfuscated bad code is bad enough, when maintaining it falls on you.

      • You know the shit I'm talking about, jamming all kinds of operations into a for() declaration, badly chosen one-letter variable names, etc..

      That's not the point IMHO, though admittedly a lot of the stuff is just that without any real content. But the real pearls would still be devious to decipher even if all identifier names were clear, and any unnecessary structural obfuscations were written in more clear way.

      • Those suckers never even got their foot in the door. I don't care how smart they think they are, we have to get products out fast, and realistically be able to maintain/upgrade them 10+ years or so.

      You need to lighten up. Some get their kicks from polisihing their car over and over, some get theirs from standing in a river in long ridiculous boots and waving a rod around, and some get it from twisting their brains around a piece of C mumbo jumbo... Nothing wrong with any of that.
    6. Re:Funny, but sickening by RichardX · · Score: 3, Funny

      Just a guess.. but you don't happen to have pointy hair?

      --
      Curiosity was framed. Ignorance killed the cat.
    7. Re:Funny, but sickening by Cygnus78 · · Score: 2, Insightful

      Calm down, it's all about having fun. They do not do this because they want to use it in production code.

    8. Re:Funny, but sickening by RPoet · · Score: 2, Informative

      Tail call elimination only reduces the amount of stack frames needed. Most of the overhead associated with function calls are still there. That said, recursion is a lot more natural in some types of languages, especially functional ones. And regardless of language, recursion can be much more intuitive and maintainable than imperative loops. Overhead isn't everything.

      --
      "Oppression and harassment is a small price to pay to live in the land of the free." -- Montgomery Burns.
    9. Re:Funny, but sickening by arcanumas · · Score: 3, Informative
      Yeah, i'm sure the guy who wrote this entry is a newbie... :)
      short main[] = {
      277, 04735, -4129, 25, 0, 477, 1019, 0xbef, 0, 12800,
      -113, 21119, 0x52d7, -1006, -7151, 0, 0x4bc, 020004,
      14880, 10541, 2056, 04010, 4548, 3044, -6716, 0x9,
      4407, 6, 5568, 1, -30460, 0, 0x9, 5570, 512, -30419,
      0x7e82, 0760, 6, 0, 4, 02400, 15, 0, 4, 1280, 4, 0,
      4, 0, 0, 0, 0x8, 0, 4, 0, ',', 0, 12, 0, 4, 0, '#',
      0, 020, 0, 4, 0, 30, 0, 026, 0, 0x6176, 120, 25712,
      'p', 072163, 'r', 29303, 29801, 'e'
      };

      Oh, here is the explanation.

      --
      Slashdot Sig. version 0.1alpha. Use at your own risk.
    10. Re:Funny, but sickening by MenTaLguY · · Score: 2, Informative

      Except a properly written recursive function, and a loop end up being exactly the same thing once compiled... Even with a C compiler

      The C standard doesn't guarantee optimization tail-recursion; and while gcc does it (to a limited extent), many compilers do not.

      Additionally, it's sometimes important to compile your code without any optimization during debugging.

      Relying on tail recursion is really only possible in languages where the standard guarantees support.

      --

      DNA just wants to be free...
    11. Re:Funny, but sickening by dubious9 · · Score: 4, Insightful

      I'd be more impressed with people who can prove they have the discipline to avoid obfuscations.

      Have you ever read any of the code? Besides formatting, (you can run stuff through indent), this stuff is *very careful* obfuscation. It's not just nonsensical variable names and lack of comments. It's using constructs in novel ways, and comming up with non-trivial solutions to what are quite often complex problems.

      If you can win this contest you know exactly what makes programs hard to read, and thereby in real situations, avoid them. Furthermore, some of the stuff is beautifully arranged and may be faster or more elegant than the easy to read version. It's not a mockery of the language, it's "art in c", and I would happily hire any of the winners as most probably they are masters of the nuances of c.

      --
      Why, o why must the sky fall when I've learned to fly?
  13. Transcript by k4_pacific · · Score: 4, Funny

    Here's an excerpt from the award ceremony:

    winner: I won! I won!
    MC: No, you're failing computer science.
    winner: [Segmentation fault]

    --
    Unknown host pong.
  14. IOCCC? or IOC-C-C? by TheShadowHawk · · Score: 4, Funny

    Since the Olympics have just finished and still reasonably fresh on my mind, did anyone else read that as a stuttered IOC-C-C? (International Olympic C-C-Committee)

    No? J-J-Just me then?

    --
    Friends don't let Friends use Internet Explorer.
  15. Bumper Sticker by pr0nbot · · Score: 3, Funny

    Chucklesome bumper sticker mentioned by someone on Slashdot...

    "Eschew Obfuscation"

  16. We get an award, too! by justkarl · · Score: 4, Funny

    And the Lifetime Acheivement in Server Destruction Award goes to...Slashdot!!! Congratulations!

    Seriously, I can practically smell the server melting from here.

  17. I think we just... by kkovach · · Score: 4, Funny

    obfuscated their webserver. :-)

    - Kevin

    --
    The less confident you are, the more serious you have to act.
  18. Re:More tricks by Bastian · · Score: 5, Interesting

    Recursive calls to main(), if handled with interesting tricks like vectored execution and such, can really spice up a program.

    If you use the trick of storing all of your data in one huge 'array', try to overlap anything you can get away with overlapping. For example, if you have a constant whose most significant byte is the same as the least significant byte in a string, there's not sense in storing that byte twice.

    While not allowed in IOCCC itself, try mixing your C with a language that's even more incomprehensible than C. I had good luck with writing a C program that sent PostScript code to a printer and having all the real work be done in the PostScript code.

  19. For those of you who don't want to wait... by jtnishi · · Score: 5, Informative
    For at least one of the entries (Don Yang's, who won the Best Utility category), the code is already up on the internet:

    http://uguu.org/src_rinia_c.html

    The only reason I can even remember where this entry would be is because he's the one a few years ago that won with that strange Saitou-Aku-Soku-Zan combination program. Yeah, I could find utilities to do what his code can do on many other places, but what better way to show your anime fandom & code fanaticism by running something like this instead. ^_^

  20. In other news... by KoolDude · · Score: 3, Funny


    All prize money for the latest IOCCC have been used up for bandwidth after a %^&*@#@%#^% ( obfuscated ) slashdot effect hit the site soon after results were published. We are sorry for the winners...

    --
    getSexySig(); /* returns sexy signature */
  21. Re:Funny about that language by falsifian · · Score: 2, Informative

    Speed. How many programming-language benchmarks are there that don't find C to produce the fastest code, not counting assembly/machine code? For example, interpreted languagues like LISP are completely impractical for something like a raytracer, unless someone makes a miraculously good LISP compiler.

    Also, C is something of a standard language. At least on UNIX-style systems, programs written in any other language have to use some glue-code library to allow them to use standard libraries, system calls, etc. (C++ is close enough to C not to, but I've had a few frustrations with C++ symbols being named differently from C symbols.)

    Anyway, any language that allows you to do everything that C does also allows you to make the same mistakes. Yes, it's probably easier to make them in C than, say... *ducks* Pascal, but it's not an insurmountable problem.

    To be honest, I've never written a C program that required any security, but I hope this helps anyway.

    --
    Each language has its purpose, however humble. -- The Tao of Programming
  22. /*Why did I do this*/ by wiredog · · Score: 2, Interesting
    Comment seen in someone else's code just before a block of especially hairy code which, it turned out, used pow() to determine which bits were set in a 16 bit int which was used to hold flags used to determine if certain data was being used. It looked sort of like:

    while(pow(something,16)==n)
    {
    if(something)
    {
    for(something else)
    {
    ...

    This was on an embedded system where using one 16 bit int instead of 16 8-bit chars to hold the flags resulted in a vital savings of memory.

  23. missing the point by Speare · · Score: 2, Insightful

    Anyone can write unreadable code.

    It takes an artist to write code that is both unreadable and beautiful at the same time.

    If your entry isn't beautiful, you're just a bad programmer.

    --
    [ .sig file not found ]
  24. You've passed over many good people then... by rarose · · Score: 4, Insightful

    Those suckers never even got their foot in the door. I don't care how smart they think they are, we have to get products out fast, and realistically be able to maintain/upgrade them 10+ years or so.

    At a couple of the companies I've been with we'd have after-hours informal little "Who can optimize this code the most" contests and they were amazingly instructive. They force you to think about solutions in new and creative ways, and to really understand an algorithm or CPU at a far deeper level than a simple straightforward implementation.

    And while those obscenely optimized implementations may never get near the shipping product, you always walk away with a far far better grasp of how the shipping code really does work. (And yes, we've discovered bugs by inspection... because the little optimization contest had us questioning assumptions that the shipping code relied upon)

    --
    --Rob
  25. More C-related sillyness by cjellibebi · · Score: 2, Funny

    Slightly offtopic, but this will serve the needs of those of us reading this thread for a fix of C-related humour. The Infrequently asked questions in C (C-IAQ)

  26. Re:More tricks by Bastian · · Score: 2, Interesting

    While a lot of stuff folks did back in the day, a lot of times there wasn't much choice. If you don't have enough (memory | speed) to accomplish the task at hand, you'll start resorting to ugly hacks. There are some interesting articles out there on all the horrible things programmers did to old game systems like the Atari 2600 and the Intellivision that would be considered Hateful today but were necessary to create a lot of good games at the time.

    The real problem is lack of documentation, and it's a problem to this day, especially when a programmer is working on a project alone. I know I'm guilty. You should take a look at some of the code I've been writing in the past week. It's like I couldn't put two slashes together to save my life.

  27. IOCCC mirrors needed by chongo · · Score: 4, Informative
    When we release the IOCCC winners, we are going to need more mirrors. If you want to mirror the IOCCC, please send EMail to Simon Cooper at:

    mirror-request at ioccc dot org

    Please include the following words in the subject of your EMail message:

    IOCCC 2004

    We will ask you a few questions and provide you with information on how we would prefer you to mirror the site. Please don't start mirroring until we have responded and processed your mirror request. Thanks in advance for your willingness to help.

    --
    chongo (was here) /\oo/\
  28. IOCCC - FAQ and History by chongo · · Score: 2, Informative
    Several people have asked / wondered what the International Obfuscated Code Content was all about, how it got start, etc.

    Definition

    Obfuscate: tr.v. -cated, -cating, -cates. 1. a. To render obscure. b. To darken. 2. To confuse: his emotions obfuscated his judgment. [LLat. obfuscare, to darken : ob(intensive) + Lat. fuscare, to darken < fuscus, dark.] -obfuscation n. obfuscatory adj.

    Goals:

    • To write the most Obscure/Obfuscated C program under the content rules.
    • To show the importance of programming style, in an ironic way.
    • To stress C compilers with unusual code.
    • To illustrate some of the subtleties of the C language.
    • To provide a safe forum for poor C code. :-)

    And here is one entry from the IOCCC FAQ that talks about how the IOCCC got started:

    One day (23 March 1984 to be exact), back Larry Bassel and I (

    Landon Curt Noll) were working for National Semiconductor's Genix porting group, we were both in our offices trying to fix some very broken code. Larry had been trying to fix a bug in the classic Bourne shell (C code #defined to death to sort of look like Algol) and I had been working on the finger program from early BSD (a bug ridden finger implementation to be sure). We happened to both wander (at the same time) out to the hallway in Building 7C to clear our heads.

    We began to compare notes: ''You won't believe the code I am trying to fix''. And: ''Well you cannot imagine the brain damage level of the code I'm trying to fix''. As well as: ''It more than bad code, the author really had to try to make it this bad!''.

    After a few minutes we wandered back into my office where I posted a flame to net.lang.c inviting people to try and out obfuscate the UN*X source code we had just been working on.

    BTW: I (Landon Curt Noll) had to post this

    typo correction. Thus began the tradition of putting typos in the contest rules and guidelines ... to make them more obfuscated of course! :-)

    BTW: This posting was made back in the days when AT&T was the evil giant. Now, Microsoft makes AT&T look mild and kind in comparison. :-( (IMHO) ).

    BTW: See the story about the '' Bill Gates'' award. :-)

    OK, back to the story. We (Larry and I) received a number of entries by EMail. When we began to receive messages from outside of the US, Larry and I decided to include International in the name. The 1st IOCCC winners were posted on 17 April 1984.

    There were 4 winners in 1984:

    <dis>honorable mention

    --
    chongo (was here) /\oo/\
  29. Code Was Supposed to Be Up Today by darkonc · · Score: 2, Informative
    According to the page, the actual code for the wineners should be up mid-October.

    They intended to have the winning code available today, but the website was designed by last year's winner, and they're guessing it'll take another 6 weeks to figure it out.

    They started in January.

    --
    Sometimes boldness is in fashion. Sometimes only the brave will be bold.
  30. This is *not* ovuscation by darkonc · · Score: 2, Interesting
    The following code is not obfuscation. It's an honest attempt to split a Red Hat RPM filename into product and version.

    while($rpm=<>){ chomp $rpm;
    if( $rpm =~ s/-((?!(g77|8514|gui)-)(([0-9][-.0-9]*)?_?(?!X11)( (?i)trunk|[abix]|horde|alpha|stable|cvs|beta|gamma ))?[-_.0-9]*(([a-zZ]|([0-9]*(svn|fc|EL|FIT|FC|x|fi nal|rh|ii|pl|tp|horde|fcs|rc|pre)))[-.0-9]*)?)\.(s rc|noarch|i[3456]86).rpm//){;
    printf "name=%23s \t vers=%s\n",$rpm, $1;
    }else{ print "ugh!\n" };
    }
    Remember to remove the whitespace from the regex before running it.
    --
    Sometimes boldness is in fashion. Sometimes only the brave will be bold.