4 ms·
One of the winners of the 1st International Obfuscated C Code Contest (1984) used this technique. https://www.ioccc.org/1984/mullender/mullender.c https://www.
by _kst_ 5y ago
One of the winners of the 1st International Obfuscated C Code Contest (1984) used this technique.
https://www.ioccc.org/1984/mullender/mullender.c https://www.ioccc.org/1984/mullender/mullender.c
https://www.ioccc.org/1984/mullender/hint.text https://www.ioccc.org/1984/mullender/hint.text
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'
};
- alin23 5y agoThat’s already mentioned in the third paragraph but it’s nice of you to also include the bytecode in the comment. > Apparently in 1984, a strange program won the IOCCC where main was declared as a short main[] = {...} and somehow this did stuff and printed to the screen!
- ianhanschen 5y agoBarely mentioned, and the author makes us all die inside when they say "Too bad it was written for a whole different architecture and compiler so there is really no easy way for me to find out what it did."
- _kst_ 5y agoAs the hint explains, it's a combination of PDP-11 and VAX machine code, set up so that either system will run its own code and ignore the foreign code. You can extract a few ASCII strings from the data. As the hint says: "Can you guess what is printed? We knew you couldn't! :-)" The ASCII strings I found were "vax", "pdp", "str", "write", and " :-)".
- cptnapalm 5y agoSo not only did they write something baffling, they also wrote it so that it was semi-portable.
- andrewmcwatters 5y agoI wonder what strange and interesting things in the computing world we’ve simply lost by forgetting and from moving on.