From e7d69bc23270e8ad73d391d15d4c996ffbd33cc3 Mon Sep 17 00:00:00 2001 From: Landon Curt Noll Date: Wed, 24 Apr 2024 02:37:42 -0700 Subject: [PATCH] fix many internal links Fixed a number of internal links that need to go to the GitHub site. Ran `make www` to perform the above. --- 1984/decot/README.md | 4 +- 1984/decot/index.html | 4 +- 1984/mullender/README.md | 6 +- 1984/mullender/index.html | 6 +- 1986/marshall/README.md | 2 +- 1986/marshall/index.html | 2 +- 1989/README.md | 6 +- 1989/index.html | 6 +- 1990/tbr/README.md | 2 +- 1990/tbr/index.html | 2 +- 1991/westley/README.md | 2 +- 1991/westley/index.html | 2 +- 1992/albert/README.md | 2 +- 1992/albert/index.html | 2 +- 1992/gson/README.md | 2 +- 1992/gson/index.html | 2 +- 1992/kivinen/README.md | 2 +- 1992/kivinen/index.html | 2 +- 1992/marangon/README.md | 2 +- 1992/marangon/index.html | 2 +- 1993/rince/README.md | 2 +- 1993/rince/index.html | 2 +- 1994/dodsond2/README.md | 4 +- 1994/dodsond2/index.html | 4 +- 1994/shapiro/README.md | 10 +- 1994/shapiro/index.html | 10 +- 1994/weisberg/README.md | 2 +- 1994/weisberg/index.html | 2 +- 1994/westley/README.md | 2 +- 1994/westley/index.html | 2 +- 1996/august/README.md | 2 +- 1996/august/index.html | 2 +- 1996/schweikh2/README.md | 2 +- 1996/schweikh2/index.html | 2 +- 1996/schweikh3/README.md | 2 +- 1996/schweikh3/index.html | 2 +- 1996/westley/README.md | 4 +- 1996/westley/index.html | 4 +- 1998/banks/README.md | 2 +- 1998/banks/index.html | 2 +- 1998/fanf/README.md | 2 +- 1998/fanf/index.html | 2 +- 1998/schnitzi/README.md | 2 +- 1998/schnitzi/index.html | 2 +- 1998/schweikh1/README.md | 2 +- 1998/schweikh1/index.html | 2 +- 2000/README.md | 2 +- 2000/bmeyer/README.md | 2 +- 2000/bmeyer/index.html | 2 +- 2000/index.html | 2 +- 2000/rince/README.md | 2 +- 2000/rince/index.html | 2 +- 2000/schneiderwent/README.md | 2 +- 2000/schneiderwent/index.html | 2 +- 2000/tomx/README.md | 2 +- 2000/tomx/index.html | 2 +- 2001/anonymous/README.md | 8 +- 2001/anonymous/index.html | 8 +- 2001/bellard/README.md | 5 +- 2001/bellard/index.html | 3 +- 2004/README.md | 4 +- 2004/index.html | 4 +- 2004/jdalbec/README.md | 10 +- 2004/jdalbec/index.html | 10 +- 2004/kopczynski/README.md | 2 +- 2004/kopczynski/index.html | 2 +- 2005/aidan/README.md | 6 +- 2005/aidan/index.html | 6 +- 2006/meyer/README.md | 4 +- 2006/meyer/index.html | 2 +- 2006/sykes1/README.md | 4 +- 2006/sykes1/index.html | 4 +- 2006/toledo2/README.md | 4 +- 2006/toledo2/index.html | 4 +- 2011/blakely/README.md | 2 +- 2011/blakely/index.html | 2 +- 2011/dlowe/README.md | 8 +- 2011/dlowe/index.html | 8 +- 2011/hamaji/README.md | 4 +- 2011/hamaji/index.html | 4 +- 2011/toledo/README.md | 2 +- 2011/toledo/index.html | 2 +- 2012/deckmyn/README.md | 4 +- 2012/deckmyn/index.html | 4 +- 2012/tromp/README.md | 2 +- 2012/tromp/index.html | 2 +- 2013/birken/README.md | 2 +- 2013/birken/index.html | 2 +- 2013/cable3/README.md | 2 +- 2013/cable3/index.html | 2 +- 2013/dlowe/README.md | 6 +- 2013/dlowe/index.html | 6 +- 2013/endoh4/README.md | 2 +- 2013/endoh4/index.html | 2 +- 2013/hou/README.md | 4 +- 2013/hou/doc/example.html | 2 +- 2013/hou/doc/example.md | 2 +- 2013/hou/index.html | 4 +- 2014/skeggs/README.md | 2 +- 2014/skeggs/index.html | 2 +- 2015/README.md | 4 +- 2015/burton/README.md | 2 +- 2015/burton/index.html | 2 +- 2015/duble/README.md | 4 +- 2015/duble/index.html | 4 +- 2015/endoh1/README.md | 4 +- 2015/endoh1/index.html | 4 +- 2015/endoh3/README.md | 2 +- 2015/endoh3/index.html | 2 +- 2015/index.html | 4 +- 2018/README.md | 2 +- 2018/burton2/README.md | 49 ++--- 2018/burton2/index.html | 49 ++--- 2018/ciura/README.md | 12 +- 2018/ciura/index.html | 12 +- 2018/endoh2/README.md | 2 +- 2018/endoh2/index.html | 2 +- 2018/ferguson/README.md | 16 +- 2018/ferguson/index.html | 16 +- 2018/index.html | 2 +- 2018/mills/README.md | 6 +- 2018/mills/index.html | 6 +- 2018/yang/README.md | 14 +- 2018/yang/index.html | 14 +- 2019/adamovsky/README.md | 10 +- 2019/adamovsky/index.html | 10 +- 2019/burton/README.md | 4 +- 2019/burton/index.html | 4 +- 2019/ciura/README.md | 17 +- 2019/ciura/index.html | 17 +- 2019/diels-grabsch1/README.md | 4 +- 2019/diels-grabsch1/index.html | 4 +- 2019/dogon/README.md | 10 +- 2019/dogon/index.html | 10 +- 2019/duble/README.md | 10 +- 2019/duble/index.html | 10 +- 2019/endoh/README.md | 2 +- 2019/endoh/index.html | 2 +- 2019/giles/README.md | 2 +- 2019/giles/index.html | 2 +- 2019/lynn/README.md | 15 +- 2019/lynn/index.html | 15 +- 2019/poikola/README.md | 6 +- 2019/poikola/index.html | 6 +- 2019/yang/README.md | 2 +- 2019/yang/index.html | 2 +- 2020/burton/README.md | 2 +- 2020/burton/index.html | 2 +- 2020/endoh1/README.md | 6 +- 2020/endoh1/index.html | 6 +- 2020/endoh2/README.md | 4 +- 2020/endoh2/index.html | 4 +- 2020/endoh3/README.md | 4 +- 2020/endoh3/index.html | 4 +- 2020/ferguson1/README.md | 16 +- 2020/ferguson1/index.html | 16 +- 2020/ferguson2/README.md | 32 +-- 2020/ferguson2/index.html | 32 +-- 2020/ferguson2/recode.html | 8 +- 2020/ferguson2/recode.md | 8 +- 2020/giles/README.md | 2 +- 2020/giles/index.html | 2 +- 2020/kurdyukov1/README.md | 14 +- 2020/kurdyukov1/index.html | 14 +- 2020/kurdyukov2/README.md | 2 +- 2020/kurdyukov2/index.html | 2 +- 2020/kurdyukov3/README.md | 2 +- 2020/kurdyukov3/index.html | 2 +- 2020/kurdyukov4/README.md | 2 +- 2020/kurdyukov4/index.html | 2 +- 2020/otterness/README.md | 2 +- 2020/otterness/index.html | 2 +- 2020/yang/README.md | 4 +- 2020/yang/index.html | 4 +- sitemap.xml | 348 ++++++++++++++++----------------- 175 files changed, 645 insertions(+), 631 deletions(-) diff --git a/1984/decot/README.md b/1984/decot/README.md index e52a2a22a..af68a8a83 100644 --- a/1984/decot/README.md +++ b/1984/decot/README.md @@ -71,8 +71,8 @@ to: for(signal=0;*k *x * __FILE__ *i;) do { ``` -To see what we mean look at the [original source file](decot.orig.c). The -[alternate code](decot.alt.c) is the version that has this modification. The +To see what we mean look at the [original source file](%%REPO_URL%%/1984/decot/decot.orig.c). The +[alternate code](%%REPO_URL%%/1984/decot/decot.alt.c) is the version that has this modification. The fixed version has instead: ``` diff --git a/1984/decot/index.html b/1984/decot/index.html index 6a01d05ce..dac630ee6 100644 --- a/1984/decot/index.html +++ b/1984/decot/index.html @@ -406,8 +406,8 @@ changed it from:

    for(signal=0;*k * x * __FILE__ *i;) do {

to:

    for(signal=0;*k *x * __FILE__ *i;) do {
-

To see what we mean look at the original source file. The -alternate code is the version that has this modification. The +

To see what we mean look at the original source file. The +alternate code is the version that has this modification. The fixed version has instead:

    for(signal=0;*k *= * __FILE__ *i;) do {

Author’s remarks:

diff --git a/1984/mullender/README.md b/1984/mullender/README.md index 5e2235616..6588218d2 100644 --- a/1984/mullender/README.md +++ b/1984/mullender/README.md @@ -125,8 +125,8 @@ favorite entries! In 2023 remarks were discovered from [Sjoerd Mullender](../../authors.html#Sjoerd_Mullender), one of the authors, and so was the program that was used by the authors to generate the array that he referred to. -Because [a.out.h](a.out.h), which [gentab.c](gentab.c) uses, is not available in -all systems (like macOS) and more importantly because we wanted it to be as +Because [a.out.h](%%REPO_URL%%/1984/mullender/a.out.h), which [gentab.c](%%REPO_URL%%/1984/mullender/gentab.c) uses, +is not available in all systems (like macOS) and more importantly because we wanted it to be as close to as the original as possible we used a copy of in the *fabulous* [Unix History @@ -386,7 +386,7 @@ format randomly. So we wrote a program to choose an appropriate format at random. The program we wrote for that follows. This program actually also extracted the machine code from the object file. -NOTE from judges: see [gentab.c](gentab.c) for a copy of this file that can be +NOTE from judges: see [gentab.c](%%REPO_URL%%/1984/mullender/gentab.c) for a copy of this file that can be compiled in modern systems. ``` diff --git a/1984/mullender/index.html b/1984/mullender/index.html index 006dbd046..379eb3bd9 100644 --- a/1984/mullender/index.html +++ b/1984/mullender/index.html @@ -456,8 +456,8 @@ favorite entries!

In 2023 remarks were discovered from Sjoerd Mullender, one of the authors, and so was the program that was used by the authors to generate the array that he referred to. -Because a.out.h, which gentab.c uses, is not available in -all systems (like macOS) and more importantly because we wanted it to be as +Because a.out.h, which gentab.c uses, +is not available in all systems (like macOS) and more importantly because we wanted it to be as close to as the original as possible we used a copy of https://raw.githubusercontent.com/dspinellis/unix-history-repo/Research-Release/usr/include/a.out.h in the fabulous Unix History @@ -661,7 +661,7 @@ formats for each constant in the resulting array, and we wanted to choose the format randomly. So we wrote a program to choose an appropriate format at random. The program we wrote for that follows. This program actually also extracted the machine code from the object file.

-

NOTE from judges: see gentab.c for a copy of this file that can be +

NOTE from judges: see gentab.c for a copy of this file that can be compiled in modern systems.

    #include <stdio.h>
     #include <a.out.h>
diff --git a/1986/marshall/README.md b/1986/marshall/README.md
index 54c90a0bb..59c064072 100644
--- a/1986/marshall/README.md
+++ b/1986/marshall/README.md
@@ -27,7 +27,7 @@ if nothing else.
 
 Due to the different [conflicting problems](compilers.html) with gcc and clang, we
 instead offer the problematic code as an alternate version whereas
-[marshall.c](marshall.c) has both the infinite loop and the complicated arg to
+[marshall.c](%%REPO_URL%%/1986/marshall/marshall.c) has both the infinite loop and the complicated arg to
 `_exit()` commented out, changing the value passed into `_exit()` to `1`.
 
 
diff --git a/1986/marshall/index.html b/1986/marshall/index.html
index 54508cdb3..26504ebfa 100644
--- a/1986/marshall/index.html
+++ b/1986/marshall/index.html
@@ -393,7 +393,7 @@ if nothing else.

Alternate code:

Due to the different conflicting problems with gcc and clang, we instead offer the problematic code as an alternate version whereas -marshall.c has both the infinite loop and the complicated arg to +marshall.c has both the infinite loop and the complicated arg to _exit() commented out, changing the value passed into _exit() to 1.

Alternate build:

To see if your compiler has the problems noted:

diff --git a/1989/README.md b/1989/README.md index e47e450be..2e3c8d3a3 100644 --- a/1989/README.md +++ b/1989/README.md @@ -8,15 +8,15 @@ You may then wish to look at the Author's remarks for even more details. Instructions for use: Run `make` to compile entries (it is possible that on System V or non-Unix systems the Makefile needs to be changed). -The Makefile for ["Best self modifying program"](fubar/indx.html) always uses +The Makefile for ["Best self modifying program"](fubar/index.html) always uses the most portable version because there is no loss of functionality in -using it. In the case of the ["Best game"](tromp/README) entry, however, some +using it. In the case of the ["Best game"](tromp/index.html) entry, however, some functionality is lost in the portable version and so its Makefile uses the original program. This year, the [Best of Show](jar.2/index.html) was given to the most useful program. -The ["Strangest abuse of the rules"](jar.1/indx.html) award was given this year +The ["Strangest abuse of the rules"](jar.1/index.html) award was given this year to stress the fact that starting in 1990, compiling entries must result a regular executable file. diff --git a/1989/index.html b/1989/index.html index 1939dafb8..6fb30593f 100644 --- a/1989/index.html +++ b/1989/index.html @@ -369,13 +369,13 @@ Look at the winning source and try to figure how it does what it does! You may then wish to look at the Author’s remarks for even more details.

Instructions for use: Run make to compile entries (it is possible that on System V or non-Unix systems the Makefile needs to be changed).

-

The Makefile for “Best self modifying program” always uses +

The Makefile for “Best self modifying program” always uses the most portable version because there is no loss of functionality in -using it. In the case of the “Best game” entry, however, some +using it. In the case of the “Best game” entry, however, some functionality is lost in the portable version and so its Makefile uses the original program.

This year, the Best of Show was given to the most useful program.

-

The “Strangest abuse of the rules” award was given this year +

The “Strangest abuse of the rules” award was given this year to stress the fact that starting in 1990, compiling entries must result a regular executable file.

Rules and results were posted to diff --git a/1990/tbr/README.md b/1990/tbr/README.md index 9252af293..9a0a3c377 100644 --- a/1990/tbr/README.md +++ b/1990/tbr/README.md @@ -92,7 +92,7 @@ of the program which we include below: e(x){x<0?write(2,"?\n$ "-x/4,2),x+1||(exit(1),0):5;} ``` -and in the [alternate source](tbr.alt.c). It has the `exit()` returns `void` fix +and in the [alternate source](%%REPO_URL%%/1990/tbr/tbr.alt.c). It has the `exit()` returns `void` fix as well as the `gets()` to `fgets()` fix applied to it to make it functionally equivalent like the authors intended. diff --git a/1990/tbr/index.html b/1990/tbr/index.html index 31cfd724a..26f9a5d31 100644 --- a/1990/tbr/index.html +++ b/1990/tbr/index.html @@ -436,7 +436,7 @@ of the program which we include below:

0),e(open(*i,0)):5,t?dup2(t,1)D t):i[2]?9 D 1),e(creat(i[2],438)):2,e(execvp(*u,u))):e(chdir(u[1])*2):6;} e(x){x<0?write(2,"?\n$ "-x/4,2),x+1||(exit(1),0):5;}
-

and in the alternate source. It has the exit() returns void fix +

and in the alternate source. It has the exit() returns void fix as well as the gets() to fgets() fix applied to it to make it functionally equivalent like the authors intended.

Alternate build:

diff --git a/1991/westley/README.md b/1991/westley/README.md index 784f51448..a936fb1c9 100644 --- a/1991/westley/README.md +++ b/1991/westley/README.md @@ -61,7 +61,7 @@ game: ``` The shell script determines when the game is over, and automatically replaces -`merlyn.c` (copied from [westley.c](westley.c) with an improved version after a +`merlyn.c` (copied from [westley.c](%%REPO_URL%%/1991/westley/westley.c) with an improved version after a loss). The [ttt](%%REPO_URL%%/1991/westley/ttt.sh) script has two other modes: ``` diff --git a/1991/westley/index.html b/1991/westley/index.html index bc4150507..9ac477241 100644 --- a/1991/westley/index.html +++ b/1991/westley/index.html @@ -406,7 +406,7 @@ game:

./ttt [first_move] # <- omit first arg to have it move first ./ttt next_move

The shell script determines when the game is over, and automatically replaces -merlyn.c (copied from westley.c with an improved version after a +merlyn.c (copied from westley.c with an improved version after a loss). The ttt script has two other modes:

    ./ttt quitgame      # cancel any game in progress, revert to merlyn.c
     ./ttt clobber       # remove all game files, revert to original source
diff --git a/1992/albert/README.md b/1992/albert/README.md index 890d88d4d..316a8cfdc 100644 --- a/1992/albert/README.md +++ b/1992/albert/README.md @@ -57,7 +57,7 @@ judges this Email message: ``` The [albert.alt.c](%%REPO_URL%%/1992/albert/albert.c) file is the fixed file, whereas the -[albert.c](1992/albert/1992/albert/lbert.c) is the file before applying Leo Broukhis' fix. +[albert.c](%%REPO_URL%%/1992/albert/1992/albert/lbert.c) is the file before applying Leo Broukhis' fix. ### Alternate build: diff --git a/1992/albert/index.html b/1992/albert/index.html index 70a86c610..2c5eadddb 100644 --- a/1992/albert/index.html +++ b/1992/albert/index.html @@ -407,7 +407,7 @@ judges this Email message:

Both albert and albert.orig loop without printing anything, although the first factor is 101 and is usually found in an instant.

The albert.alt.c file is the fixed file, whereas the -albert.c is the file before applying Leo Broukhis’ fix.

+albert.c is the file before applying Leo Broukhis’ fix.

Alternate build:

To compile this alternate version:

    make alt
diff --git a/1992/gson/README.md b/1992/gson/README.md index ee0abc6e9..e39394fa0 100644 --- a/1992/gson/README.md +++ b/1992/gson/README.md @@ -58,7 +58,7 @@ Then using the proper dictionary file it does: where `/usr/share/dict/words` is the dictionary file. Then it uses the [mkdict.sh](%%REPO_URL%%/1992/gson/mkdict.sh) script to create a dictionary file out -of the files [README.md](%%REPO_URL%%/1992/gson/README.md), [try.sh](try.sh) (itself) and +of the files [index.html](%%REPO_URL%%/1992/gson/index.html), [try.sh](%%REPO_URL%%/1992/gson/try.sh) (itself) and [Makefile](%%REPO_URL%%/1992/gson/Makefile) and it repeats the same commands as above. In the case no dictionary file can be found in the first step it only runs the commands once with the created dictionary file. diff --git a/1992/gson/index.html b/1992/gson/index.html index 235567c25..9bcaef8c6 100644 --- a/1992/gson/index.html +++ b/1992/gson/index.html @@ -406,7 +406,7 @@ following locations though the last one is more ironic:

./ag paul e tsongas < /usr/share/dict/words

where /usr/share/dict/words is the dictionary file.

Then it uses the mkdict.sh script to create a dictionary file out -of the files README.md, try.sh (itself) and +of the files index.html, try.sh (itself) and Makefile and it repeats the same commands as above. In the case no dictionary file can be found in the first step it only runs the commands once with the created dictionary file.

diff --git a/1992/kivinen/README.md b/1992/kivinen/README.md index 1a3b0674f..a482642b0 100644 --- a/1992/kivinen/README.md +++ b/1992/kivinen/README.md @@ -77,7 +77,7 @@ you have with the program. :-) NOTE: Some systems do not need (or have) `-lsocket -lresolv -lnsl`. Such systems should compile using `-lX11`. -NOTE: The original winning source [kivinen.orig.c](kivinen.orig.c) assumed that +NOTE: The original winning source [kivinen.orig.c](%%REPO_URL%%/1992/kivinen/kivinen.orig.c) assumed that `exit(3)` returned a value which cause problems for some systems where `exit(3)` returns `void`. The file [kivinen.c](%%REPO_URL%%/1992/kivinen/kivinen.c) avoids this problem. diff --git a/1992/kivinen/index.html b/1992/kivinen/index.html index 5e0644849..aa149cc4e 100644 --- a/1992/kivinen/index.html +++ b/1992/kivinen/index.html @@ -414,7 +414,7 @@ code.

you have with the program. :-)

NOTE: Some systems do not need (or have) -lsocket -lresolv -lnsl. Such systems should compile using -lX11.

-

NOTE: The original winning source kivinen.orig.c assumed that +

NOTE: The original winning source kivinen.orig.c assumed that exit(3) returned a value which cause problems for some systems where exit(3) returns void. The file kivinen.c avoids this problem.

Author’s remarks:

diff --git a/1992/marangon/README.md b/1992/marangon/README.md index 964f67175..af034cf1f 100644 --- a/1992/marangon/README.md +++ b/1992/marangon/README.md @@ -22,7 +22,7 @@ NOTE: Some compilers have had trouble optimizing this entry. NOTE: Some systems need to compile with `-ltermcap` as well as `-lcurses`. -NOTE: The original winning source [marangon.orig.c](marangon.orig.c), found in +NOTE: The original winning source [marangon.orig.c](%%REPO_URL%%/1992/marangon/marangon.orig.c), found in the archive directory, assumed that `exit(3)` returns a value which cause problems for some systems where `exit(3)` returns a `void`. The file [marangon.c](%%REPO_URL%%/1992/marangon/marangon.c) avoids this problem. diff --git a/1992/marangon/index.html b/1992/marangon/index.html index 773f6e711..d9d12efd9 100644 --- a/1992/marangon/index.html +++ b/1992/marangon/index.html @@ -387,7 +387,7 @@ numbers as needed. It is the side effects that get you into trouble. If you are not careful, you may find things “at 6’s and 7’s”. :-)

NOTE: Some compilers have had trouble optimizing this entry.

NOTE: Some systems need to compile with -ltermcap as well as -lcurses.

-

NOTE: The original winning source marangon.orig.c, found in +

NOTE: The original winning source marangon.orig.c, found in the archive directory, assumed that exit(3) returns a value which cause problems for some systems where exit(3) returns a void. The file marangon.c avoids this problem.

diff --git a/1993/rince/README.md b/1993/rince/README.md index ac03f4956..a65db0368 100644 --- a/1993/rince/README.md +++ b/1993/rince/README.md @@ -49,7 +49,7 @@ and to another value like 18 or 19 which you can do with the alternate code. -In the case of [rince.alt2.c](rince.alt2.c) the movement keys for the default +In the case of [rince.alt2.c](%%REPO_URL%%/1993/rince/rince.alt2.c) the movement keys for the default game are slightly different and will feel more familiar to vi users: `h` for left, `l` for right (that was not changed) and `k` for fire (that was also not changed). diff --git a/1993/rince/index.html b/1993/rince/index.html index 39919c64e..521d68554 100644 --- a/1993/rince/index.html +++ b/1993/rince/index.html @@ -397,7 +397,7 @@ value 17 in the lines:

and

    refresh(),c=select(k,&y,0,0,(v.tv_usec=1<<17,&v))?getch():0;

to another value like 18 or 19 which you can do with the alternate code.

-

In the case of rince.alt2.c the movement keys for the default +

In the case of rince.alt2.c the movement keys for the default game are slightly different and will feel more familiar to vi users: h for left, l for right (that was not changed) and k for fire (that was also not changed).

diff --git a/1994/dodsond2/README.md b/1994/dodsond2/README.md index 55108efe7..32a020e3d 100644 --- a/1994/dodsond2/README.md +++ b/1994/dodsond2/README.md @@ -84,8 +84,8 @@ in an effort to get around the 1994 version of Rule 2: followed by either whitespace or end of file, must be <= 1536. ``` -Indeed, when [dodsond2.gz](dodsond2.gz) is uncompressed, it is identical -to the [dodsond2.c](%%REPO_URL%%/1994/dodsond2/dodsond2.c) file you find today. +Indeed the [dodsond2.c](%%REPO_URL%%/1994/dodsond2/dodsond2.c) file is +what you find today. The IOCCC rules and guidelines were modified in an effort to address this fun "_abuse of the rules_" style hack. diff --git a/1994/dodsond2/index.html b/1994/dodsond2/index.html index ca32e35c0..60ee8cec3 100644 --- a/1994/dodsond2/index.html +++ b/1994/dodsond2/index.html @@ -414,8 +414,8 @@ in an effort to get around the 1994 version of Rule 2:

    2) Your entry must be <= 3217 bytes in length.  The number of characters
        excluding whitespace (tab, space, newline), and excluding any ; { or }
        followed by either whitespace or end of file, must be <= 1536.
-

Indeed, when dodsond2.gz is uncompressed, it is identical -to the dodsond2.c file you find today.

+

Indeed the dodsond2.c file is +what you find today.

The IOCCC rules and guidelines were modified in an effort to address this fun “abuse of the rules” style hack.

It is worth noting that without this compression “abuse of the rules” diff --git a/1994/shapiro/README.md b/1994/shapiro/README.md index 0dff6ad5c..4ee67bbd4 100644 --- a/1994/shapiro/README.md +++ b/1994/shapiro/README.md @@ -51,7 +51,7 @@ source file is self documenting. :-) From time to time, run `ps(1)` and look at the new processes. See [shapiro.html](shapiro.html) for more information in the internals of this program. -The file [shapiro.alt.c](shapiro.alt.c) contains a non-obfuscated version of +The file [shapiro.alt.c](%%REPO_URL%%/1994/shapiro/shapiro.alt.c) contains a non-obfuscated version of this program. Note that this alt file is currently missing. See [1994 shapiro bugs](../../bugs.html#1994_shapiro) for details. @@ -67,18 +67,18 @@ The basic theme (pun) of this program is: ``` -My entry ([shapiro.c](shapiro.c)) is mostly comments, formatted in the shape of a +My entry ([shapiro.c](%%REPO_URL%%/1994/shapiro/shapiro.c)) is mostly comments, formatted in the shape of a clock. If you strip out the comments and look at the code you will quickly realize that the comments were the important part and that the code does very little (see pun above). It writes (to `stdout`) -another C program ([shapiro_t2.c](shapiro_t2.c)). This is the first level of +another C program ([shapiro_t2.c](%%REPO_URL%%/1994/shapiro/shapiro_t2.c)). This is the first level of obfuscation. -The second program ([shapiro_t2.c](shapiro_t2.c) (use `make everything` first) +The second program ([shapiro_t2.c](%%REPO_URL%%/1994/shapiro/shapiro_t2.c) (use `make everything` first) prints a clock in the upper right hand corner of your VTxxx/ANSI display. Most of the surface obfuscation in the second program -([shapiro_t2.c](shapiro_t2.c)) was an attempt to make it as small as possible. +([shapiro_t2.c](%%REPO_URL%%/1994/shapiro/shapiro_t2.c)) was an attempt to make it as small as possible. You should be able to see around this with `cb(1)` and some more intelligent variable names. Once you get past this you will realize that the third level of obfuscation is a six member client/server hierarchy. (See the diff --git a/1994/shapiro/index.html b/1994/shapiro/index.html index 7e4542b13..6306263e0 100644 --- a/1994/shapiro/index.html +++ b/1994/shapiro/index.html @@ -403,23 +403,23 @@ bring it back to the foreground.

source file is self documenting. :-)

From time to time, run ps(1) and look at the new processes.

See shapiro.html for more information in the internals of this program. -The file shapiro.alt.c contains a non-obfuscated version of +The file shapiro.alt.c contains a non-obfuscated version of this program. Note that this alt file is currently missing. See 1994 shapiro bugs for details.

Author’s remarks:

The basic theme (pun) of this program is:

    "This time (everything) is not where it should be."
           ~~~~
-

My entry (shapiro.c) is mostly comments, formatted in the shape of a +

My entry (shapiro.c) is mostly comments, formatted in the shape of a clock. If you strip out the comments and look at the code you will quickly realize that the comments were the important part and that the code does very little (see pun above). It writes (to stdout) -another C program (shapiro_t2.c). This is the first level of +another C program (shapiro_t2.c). This is the first level of obfuscation.

-

The second program (shapiro_t2.c (use make everything first) +

The second program (shapiro_t2.c (use make everything first) prints a clock in the upper right hand corner of your VTxxx/ANSI display.

Most of the surface obfuscation in the second program -(shapiro_t2.c) was an attempt to make it as small as possible. +(shapiro_t2.c) was an attempt to make it as small as possible. You should be able to see around this with cb(1) and some more intelligent variable names. Once you get past this you will realize that the third level of obfuscation is a six member client/server hierarchy. (See the diff --git a/1994/weisberg/README.md b/1994/weisberg/README.md index 447b73368..8a70f5a24 100644 --- a/1994/weisberg/README.md +++ b/1994/weisberg/README.md @@ -77,7 +77,7 @@ event of a system shutdown or reboot. ### Bugs -The alternative version ([weisberg.alt.c](weisberg.alt.c)) has never actually run +The alternative version ([weisberg.alt.c](%%REPO_URL%%/1994/weisberg/weisberg.alt.c)) has never actually run to completion. After running for close to a week it had reached somewhere around 250e6, when it became necessary to test the reboot feature (which worked remarkably well). As there are quite a lot of primes to be found before reaching diff --git a/1994/weisberg/index.html b/1994/weisberg/index.html index a81a1d526..84bad6850 100644 --- a/1994/weisberg/index.html +++ b/1994/weisberg/index.html @@ -413,7 +413,7 @@ run to completion, so as an added feature, it will cease execution upon reception of a signal (any will do equally well), as well as in the event of a system shutdown or reboot.

Bugs

-

The alternative version (weisberg.alt.c) has never actually run +

The alternative version (weisberg.alt.c) has never actually run to completion. After running for close to a week it had reached somewhere around 250e6, when it became necessary to test the reboot feature (which worked remarkably well). As there are quite a lot of primes to be found before reaching diff --git a/1994/westley/README.md b/1994/westley/README.md index 981fc43d1..466df2032 100644 --- a/1994/westley/README.md +++ b/1994/westley/README.md @@ -85,7 +85,7 @@ compiler line you will get a different message (**as compiler errors** due to _This is independent of the previous (if there are any previous) compiler invocations_ specified. That means with the right compiler invocation you can -'win' the game on the first go. But unlike the [alternate code](westley.alt.c), +'win' the game on the first go. But unlike the [alternate code](%%REPO_URL%%/1994/westley/westley.alt.c), you do not run this program as it will not compile: instead it will be compiler error messages; there is no running the program. diff --git a/1994/westley/index.html b/1994/westley/index.html index 20ae198f2..7a4f3f1aa 100644 --- a/1994/westley/index.html +++ b/1994/westley/index.html @@ -427,7 +427,7 @@ compiler line you will get a different message (as compiler errors

This is independent of the previous (if there are any previous) compiler invocations specified. That means with the right compiler invocation you can -‘win’ the game on the first go. But unlike the alternate code, +‘win’ the game on the first go. But unlike the alternate code, you do not run this program as it will not compile: instead it will be compiler error messages; there is no running the program.

Original try:

diff --git a/1996/august/README.md b/1996/august/README.md index e936ff85e..b31e9bc5d 100644 --- a/1996/august/README.md +++ b/1996/august/README.md @@ -104,7 +104,7 @@ of operators, and control constructs. The compiler has absolutely no error checking, so things can go wrong. But this is what seasoned C programmers are used to. -Assume that the interpreter has been compiled (source in [august.c](august.c) +Assume that the interpreter has been compiled (source in [august.c](%%REPO_URL%%/1996/august/august.c) and binary in august) and that we have this in a file named `test.oc`: ``` diff --git a/1996/august/index.html b/1996/august/index.html index df54f4954..b25f1c093 100644 --- a/1996/august/index.html +++ b/1996/august/index.html @@ -429,7 +429,7 @@ syntax). Arrays can only be global. There is a rather limited set of operators, and control constructs.

The compiler has absolutely no error checking, so things can go wrong. But this is what seasoned C programmers are used to.

-

Assume that the interpreter has been compiled (source in august.c +

Assume that the interpreter has been compiled (source in august.c and binary in august) and that we have this in a file named test.oc:

    main() { putchar('!'); putchar('\n'); exit(0); }

We can then compile by

diff --git a/1996/schweikh2/README.md b/1996/schweikh2/README.md index c226c8291..bf4d88267 100644 --- a/1996/schweikh2/README.md +++ b/1996/schweikh2/README.md @@ -48,7 +48,7 @@ make it easier to see what is happening. ## Judges' remarks: The original program, with only slight obfuscations, may be found -in [hunni.c](%%REPO_URL%%/1996/schweikh2/hunni.c). The perl script, [hunni.pl](hunni.pl), obfuscates it +in [hunni.c](%%REPO_URL%%/1996/schweikh2/hunni.c). The perl script, [hunni.pl](%%REPO_URL%%/1996/schweikh2/hunni.pl), obfuscates it appropriately. Try: ``` diff --git a/1996/schweikh2/index.html b/1996/schweikh2/index.html index a7676f88e..8d515d777 100644 --- a/1996/schweikh2/index.html +++ b/1996/schweikh2/index.html @@ -399,7 +399,7 @@ ctrl-c to stop it. Observe how the Judges’ remarks:

The original program, with only slight obfuscations, may be found -in hunni.c. The perl script, hunni.pl, obfuscates it +in hunni.c. The perl script, hunni.pl, obfuscates it appropriately. Try:

    less hunni.c
 
diff --git a/1996/schweikh3/README.md b/1996/schweikh3/README.md
index 930c1b921..94b0239ba 100644
--- a/1996/schweikh3/README.md
+++ b/1996/schweikh3/README.md
@@ -131,7 +131,7 @@ situation and effectively halts.
 I had the pleasure and pain to find all three behaviours on the
 platforms I use regularly.
 
-The file [schweikh3.info](schweikh3.info) has output for
+The file [schweikh3.info](%%REPO_URL%%/1996/schweikh3/schweikh3.info) has output for
 Solaris, FreeBSD and Linux. The Linux case is interesting in that
 the behaviour changes when `calloc(3)` is used instead of `malloc(3)`.
 For FreeBSD, the last two lines are not messages stemming from
diff --git a/1996/schweikh3/index.html b/1996/schweikh3/index.html
index 485ea76b2..ebd59b00e 100644
--- a/1996/schweikh3/index.html
+++ b/1996/schweikh3/index.html
@@ -463,7 +463,7 @@ situation and effectively halts.

I had the pleasure and pain to find all three behaviours on the platforms I use regularly.

-

The file schweikh3.info has output for +

The file schweikh3.info has output for Solaris, FreeBSD and Linux. The Linux case is interesting in that the behaviour changes when calloc(3) is used instead of malloc(3). For FreeBSD, the last two lines are not messages stemming from diff --git a/1996/westley/README.md b/1996/westley/README.md index 28d24dabe..476a44a6a 100644 --- a/1996/westley/README.md +++ b/1996/westley/README.md @@ -60,8 +60,8 @@ This 1-line program allows various analog ASCII clocks to print out the time; the ASCII clock is built from the command line arguments, so many different types of clocks can be generated. Three different scripts are supplied to print out a grandfather clock, a mantle clock that runs backwards, and a linear-style -clock. (they are [clock1.sh](clock1.sh), [clock2.sh](clock2.sh), and -[clock3.sh](clock3.sh)) +clock. (they are [clock1.sh](%%REPO_URL%%/1996/westley/clock1.sh), [clock2.sh](%%REPO_URL%%/1996/westley/clock2.sh), and +[clock3.sh](%%REPO_URL%%/1996/westley/clock3.sh)) The program makes the following (possibly non-portable) assumptions: diff --git a/1996/westley/index.html b/1996/westley/index.html index c37f68bd0..5f3da1911 100644 --- a/1996/westley/index.html +++ b/1996/westley/index.html @@ -406,8 +406,8 @@ understand it.

the ASCII clock is built from the command line arguments, so many different types of clocks can be generated. Three different scripts are supplied to print out a grandfather clock, a mantle clock that runs backwards, and a linear-style -clock. (they are clock1.sh, clock2.sh, and -clock3.sh)

+clock. (they are clock1.sh, clock2.sh, and +clock3.sh)

The program makes the following (possibly non-portable) assumptions:

  1. Command line strings can be written to.

  2. diff --git a/1998/banks/README.md b/1998/banks/README.md index 71c859cd8..ca5d12e97 100644 --- a/1998/banks/README.md +++ b/1998/banks/README.md @@ -219,7 +219,7 @@ Here is a brief description of the scenery files: Simple obstacle course. Try to fly over the buildings and under the bridges. -- [pyramids.sc](1998/banks/pyramids.sc) +- [pyramids.sc](%%REPO_URL%%/1998/banks/pyramids.sc) Fly over the tombs of the ancient Pharaohs, in this (fictitious) Egyptian landscape. diff --git a/1998/banks/index.html b/1998/banks/index.html index 8d86993b2..4377a4a84 100644 --- a/1998/banks/index.html +++ b/1998/banks/index.html @@ -519,7 +519,7 @@ to your right.

  3. bb.sc

    Simple obstacle course. Try to fly over the buildings and under the bridges.

  4. -
  5. pyramids.sc

    +
  6. pyramids.sc

    Fly over the tombs of the ancient Pharaohs, in this (fictitious) Egyptian landscape.

  7. river.sc

    diff --git a/1998/fanf/README.md b/1998/fanf/README.md index 5c08f365e..0e62ccbde 100644 --- a/1998/fanf/README.md +++ b/1998/fanf/README.md @@ -28,7 +28,7 @@ Enter an expression on standard input. To try some we have selected: ### Historical aside: -At a time the code in [fanf.c](%%REPO_URL%%/1998/fanf/fanf.c) was that of [fanf.orig.c](fanf.orig.c) +At a time the code in [fanf.c](%%REPO_URL%%/1998/fanf/fanf.c) was that of [fanf.orig.c](%%REPO_URL%%/1998/fanf/fanf.orig.c) but to get this to compile in modern systems it had to be translated to what you now see. The intermediate steps can still be performed but they might be different from the past. This should be kept in mind as you read the below diff --git a/1998/fanf/index.html b/1998/fanf/index.html index 9399ee304..a416d0bb0 100644 --- a/1998/fanf/index.html +++ b/1998/fanf/index.html @@ -388,7 +388,7 @@ this entry because of the system resources it requires.

        ./try.sh

    Judges’ remarks:

    Historical aside:

    -

    At a time the code in fanf.c was that of fanf.orig.c +

    At a time the code in fanf.c was that of fanf.orig.c but to get this to compile in modern systems it had to be translated to what you now see. The intermediate steps can still be performed but they might be different from the past. This should be kept in mind as you read the below diff --git a/1998/schnitzi/README.md b/1998/schnitzi/README.md index cbec70cfd..d7fc68330 100644 --- a/1998/schnitzi/README.md +++ b/1998/schnitzi/README.md @@ -78,7 +78,7 @@ the letter `e`. The IOCCC has been no stranger to this concept. Several winning entries from years past have accomplished interesting feats while completely avoiding the use of certain C constructs thought to be essential (e.g. -[1988/robison.c](../../1988/robison/robison.c)). If you have to ask why they would +[1988/robison.c](%%REPO_URL%%/1988/robison/robison.c)). If you have to ask why they would do it this way, then this contest just isn't for you. In continuing with this fine tradition, this program suggests to the ANSI diff --git a/1998/schnitzi/index.html b/1998/schnitzi/index.html index 957578ffc..e86873ac8 100644 --- a/1998/schnitzi/index.html +++ b/1998/schnitzi/index.html @@ -422,7 +422,7 @@ the letter e.

    The IOCCC has been no stranger to this concept. Several winning entries from years past have accomplished interesting feats while completely avoiding the use of certain C constructs thought to be essential (e.g. -1988/robison.c). If you have to ask why they would +1988/robison.c). If you have to ask why they would do it this way, then this contest just isn’t for you.

    In continuing with this fine tradition, this program suggests to the ANSI committee some new practical simplifications for the C language. For instance, diff --git a/1998/schweikh1/README.md b/1998/schweikh1/README.md index c7729e283..e6b90de6e 100644 --- a/1998/schweikh1/README.md +++ b/1998/schweikh1/README.md @@ -247,7 +247,7 @@ printer when you make a hard copy of the source... While I'm at it, the rules state that only space, tab and newline are ignored for the count (plus '`{`', '`}`', '`;`' followed by -whitespace). The [mkentry.c](../mkentry.c) program, however, uses `isspace(3)` which +whitespace). The [mkentry.c](%%REPO_URL%%/1998/mkentry.c) program, however, uses `isspace(3)` which returns nonzero for `\v` and `\f` and other characters as well. I could have used a lot more `^K` and `^L` probably undetected by your counter but decided to err on the side of safety. I use a perl diff --git a/1998/schweikh1/index.html b/1998/schweikh1/index.html index 85e81b98e..ed2722cca 100644 --- a/1998/schweikh1/index.html +++ b/1998/schweikh1/index.html @@ -546,7 +546,7 @@ something new – after 14 years of IOCCC. Be sure to have enough paper in your printer when you make a hard copy of the source…

    While I’m at it, the rules state that only space, tab and newline are ignored for the count (plus ‘{’, ‘}’, ‘;’ followed by -whitespace). The mkentry.c program, however, uses isspace(3) which +whitespace). The mkentry.c program, however, uses isspace(3) which returns nonzero for \v and \f and other characters as well. I could have used a lot more ^K and ^L probably undetected by your counter but decided to err on the side of safety. I use a perl diff --git a/2000/README.md b/2000/README.md index 94895be1e..e9b7e9206 100644 --- a/2000/README.md +++ b/2000/README.md @@ -45,7 +45,7 @@ them for the next IOCCC. We believe you will be impressed with this year's winning entries. The [Best of Show](jarijyrki/index.html) is a fine example of compact obfuscation. But don't ignore the shorter entries. The [Best Small Program](natori/index.html), [Best -Abuse of User](briddlebane/README.m) and [Most Complete Program](tomx/index.html) +Abuse of User](briddlebane/index.html) and [Most Complete Program](tomx/index.html) are well worth studying in detail. The [Worst Abuse of the Rules](dlowe/index.html) is technically allowed by the diff --git a/2000/bmeyer/README.md b/2000/bmeyer/README.md index 7e13881b7..146a5775d 100644 --- a/2000/bmeyer/README.md +++ b/2000/bmeyer/README.md @@ -324,7 +324,7 @@ en/decoded[^4]. ### Photo Credit: [Lavabus](%%REPO_URL%%/2000/bmeyer/lavabus.pgm) was taken by the judge, Landon Curt Noll. -[Michael](%%REPO_URL%%/2000/bmeyer/michael.pgm) was provided by the author. [Lenna](lenna.glic) is a +[Michael](%%REPO_URL%%/2000/bmeyer/michael.pgm) was provided by the author. [Lenna](%%REPO_URL%%/2000/bmeyer/lenna.glic) is a 1972 Playboy centerfold (doesn't show very much). - [michael.pgm](%%REPO_URL%%/2000/bmeyer/michael.pgm) diff --git a/2000/bmeyer/index.html b/2000/bmeyer/index.html index bfc846303..8ea6eb668 100644 --- a/2000/bmeyer/index.html +++ b/2000/bmeyer/index.html @@ -584,7 +584,7 @@ interval halving repeated until the precise value has been en/decoded5.

    Photo Credit:

    Lavabus was taken by the judge, Landon Curt Noll. -Michael was provided by the author. Lenna is a +Michael was provided by the author. Lenna is a 1972 Playboy centerfold (doesn’t show very much).

NOTE: if the 32-bit version cannot be compiled the script will at least compile -anonymous.ten as a 64-bit program (or whatever your system is +anonymous.ten as a 64-bit program (or whatever your system is set to) and run it directly.

What happens if the x86 program has already been modified by this program? The judges’ remarks below might give you a hint!

@@ -436,7 +436,7 @@ quite a lot of bit twiddling.

run x86 programs on any machine (x86 or otherwise).

I have included a simple 10 Green Bottles -program (try make anonymous.ten), meant to be compiled as a +program (try make anonymous.ten), meant to be compiled as a 32-bit ELF binary.

The program anonymous.ten, and its source (dull) are included as data files.

@@ -453,7 +453,7 @@ generates a translation for an entire basic block of subject code. Having translated a block once, the target code generated will be stored for the duration that the program is running, so as a program runs its performance will improve, as it hits cached blocks. This can be clearly observed in the example -program, anonymous.ten which must be compiled as a 32-bit ELF +program, anonymous.ten which must be compiled as a 32-bit ELF binary.

Target Library Linking:

The program runs dynamically @@ -523,7 +523,7 @@ turn up - yes the program is unsafe, but it’s pretty cool anyway.

anonymous.ten program. Other trivial x86 programs may run on the translator - and I have successfully run a wide range of “Hello World” programs, including one of last year’s IOCCC entries, -tomx.

+tomx.

Complete Program

The fact that the program makes calls to system(3) and execv(3) may imply that it is not a complete program in its own right, as it relies on other programs. diff --git a/2001/bellard/README.md b/2001/bellard/README.md index bee0b9db5..f159d7c57 100644 --- a/2001/bellard/README.md +++ b/2001/bellard/README.md @@ -82,7 +82,10 @@ put `#!/usr/local/bin/otcc` at the beginning of your C source if you installed `otcc` at this place. -### Supported C language subset (read joint example [bellard.otccex.c](bellard.otccex.c) to have an introduction to `OTCC` dialect) +### Supported C language subset + + +Read joint example [bellard.otccex.c](%%REPO_URL%%/2001/bellard/bellard.otccex.c) to have an introduction to `OTCC` dialect. #### Expressions: diff --git a/2001/bellard/index.html b/2001/bellard/index.html index d92172b16..57d9ce546 100644 --- a/2001/bellard/index.html +++ b/2001/bellard/index.html @@ -418,7 +418,8 @@ program.

An alternate syntax is to use it as a script interpreter: you can put #!/usr/local/bin/otcc at the beginning of your C source if you installed otcc at this place.

-

Supported C language subset (read joint example bellard.otccex.c to have an introduction to OTCC dialect)

+

Supported C language subset

+

Read joint example bellard.otccex.c to have an introduction to OTCC dialect.

Expressions:

  • binary operators, in decreasing precedence order: * / %, diff --git a/2004/README.md b/2004/README.md index c2b2f38ca..e6a6c3e62 100644 --- a/2004/README.md +++ b/2004/README.md @@ -26,11 +26,11 @@ local compiler. ## Remarks on some of the entries We believe you will be impressed with this year's winning entries. The [Best of -Show](gavin/gavin.c) is a fine example of obfuscation. But don't ignore the +Show](%%REPO_URL%%/2004/gavin/gavin.c) is a fine example of obfuscation. But don't ignore the other entries! There are games, utilities, programs that output images and a one-liner that is incredibly compact for what it can do. -The [Best Abuse of the Guidelines](hibachi/hibachi.c) is technically allowed by +The [Best Abuse of the Guidelines](%%REPO_URL%%/2004/hibachi/hibachi.c) is technically allowed by the rules. This year we allowed it due to the functionality of the program. This entry is one of the easiest to read! Don't assume you can win using similar techniques next time ... :-) diff --git a/2004/index.html b/2004/index.html index 6348628f0..8494b3bc8 100644 --- a/2004/index.html +++ b/2004/index.html @@ -379,11 +379,11 @@ require certain changes (add or remove a library, add or remove a yours is lacking, you may need to compile using gcc instead of your local compiler.

    Remarks on some of the entries

    -

    We believe you will be impressed with this year’s winning entries. The Best of +

    We believe you will be impressed with this year’s winning entries. The Best of Show is a fine example of obfuscation. But don’t ignore the other entries! There are games, utilities, programs that output images and a one-liner that is incredibly compact for what it can do.

    -

    The Best Abuse of the Guidelines is technically allowed by +

    The Best Abuse of the Guidelines is technically allowed by the rules. This year we allowed it due to the functionality of the program. This entry is one of the easiest to read! Don’t assume you can win using similar techniques next time … :-)

    diff --git a/2004/jdalbec/README.md b/2004/jdalbec/README.md index 6891e0571..337d5c545 100644 --- a/2004/jdalbec/README.md +++ b/2004/jdalbec/README.md @@ -114,7 +114,7 @@ last digit. Four common elements could also be written as isotopes of these two elements: `He=Np(2)`, `Li=Pu(2)`, `Ta=Np(3)`, `W=Pu(3)`. To get other isotopes, just change the last digit to a number greater than 3. -The build file runs [jdalbec.c](jdalbec.c) through the C preprocessor to +The build file runs [jdalbec.c](%%REPO_URL%%/2004/jdalbec/jdalbec.c) through the C preprocessor to generate `jdalbec2.c` which is edited with `ed(1)` (NOTE: this was changed to `sed(1)` by the judges) to correct spacing problems caused by some preprocessors. (I know you dislike @@ -122,10 +122,10 @@ Perl, but hopefully `ed(1)` is more common on POSIX systems than Perl.) The build file then compiles `jdalbec2.c]` and removes the `jdalbec2.c` file. -I don't think I'm abusing the [Makefile](Makefile) since I'm only using +I don't think I'm abusing the [Makefile](%%REPO_URL%%/2004/jdalbec/Makefile) since I'm only using 147 characters including white space and the `#!` line and the commented-out `-Wall -pedantic` options. The [rules for the -16th IOCCC](../../2004/rules.txt) specifically allowed build files up to 521 +16th IOCCC](../rules.txt) specifically allowed build files up to 521 characters long so my build file would have been well within those limits. (What typo?) @@ -168,7 +168,7 @@ line 3 because the compiler doesn't recognize `??=` as a trigraph step on Mac OS X 10.1.5 generates lots of errors in "smart mode" because the "smart" preprocessor expects a valid C program as input. The preprocessor then falls back to "basic -mode" and preprocesses [jdalbec.c](jdalbec.c) successfully without warnings, +mode" and preprocesses [jdalbec.c](%%REPO_URL%%/2004/jdalbec/jdalbec.c) successfully without warnings, even when I give it the `-Wall -pedantic` options. It inserts a lot of extra spaces into the preprocessed output which is why I had to add the `ed(1)` step to the build file so that my @@ -191,7 +191,7 @@ it if you run into this feature (e.g. `1 22` instead of `122`). Note: you may want to be sure you have a limit on stack size before trying this. I ran it on Debian GNU/Linux and discovered that I did not have a limit on stack size. Fortunately the OS killed the process after a while. This is consistent -with the output of [1996/schweikh3](../../1996/schweikh3/schweikh3.c) which reports +with the output of [1996/schweikh3](%%REPO_URL%%/1996/schweikh3/schweikh3.c) which reports `malloc lied! Killed by SIGKILL`. Arguments matching `/(?:.){10,}/` will produce visually incorrect diff --git a/2004/jdalbec/index.html b/2004/jdalbec/index.html index 2133788fe..e136ae00d 100644 --- a/2004/jdalbec/index.html +++ b/2004/jdalbec/index.html @@ -434,16 +434,16 @@ the isotopes of last digit. Four common elements could also be written as isotopes of these two elements: He=Np(2), Li=Pu(2), Ta=Np(3), W=Pu(3). To get other isotopes, just change the last digit to a number greater than 3.

    -

    The build file runs jdalbec.c through the C preprocessor to +

    The build file runs jdalbec.c through the C preprocessor to generate jdalbec2.c which is edited with ed(1) (NOTE: this was changed to sed(1) by the judges) to correct spacing problems caused by some preprocessors. (I know you dislike Perl, but hopefully ed(1) is more common on POSIX systems than Perl.) The build file then compiles jdalbec2.c] and removes the jdalbec2.c file.

    -

    I don’t think I’m abusing the Makefile since I’m only using +

    I don’t think I’m abusing the Makefile since I’m only using 147 characters including white space and the #! line and the -commented-out -Wall -pedantic options. The rules for the +commented-out -Wall -pedantic options. The rules for the 16th IOCCC specifically allowed build files up to 521 characters long so my build file would have been well within those limits. (What typo?)

    @@ -481,7 +481,7 @@ line 3 because the compiler doesn’t recognize ??= as a trigraph step on Mac OS X 10.1.5 generates lots of errors in “smart mode” because the “smart” preprocessor expects a valid C program as input. The preprocessor then falls back to “basic -mode” and preprocesses jdalbec.c successfully without warnings, +mode” and preprocesses jdalbec.c successfully without warnings, even when I give it the -Wall -pedantic options. It inserts a lot of extra spaces into the preprocessed output which is why I had to add the ed(1) step to the build file so that my @@ -500,7 +500,7 @@ it if you run into this feature (e.g. 1 22 instead of 122Note: you may want to be sure you have a limit on stack size before trying this. I ran it on Debian GNU/Linux and discovered that I did not have a limit on stack size. Fortunately the OS killed the process after a while. This is consistent -with the output of 1996/schweikh3 which reports +with the output of 1996/schweikh3 which reports malloc lied! Killed by SIGKILL.

    Arguments matching /(?:.){10,}/ will produce visually incorrect results (e.g., generation 1 starting from 1111111111 will diff --git a/2004/kopczynski/README.md b/2004/kopczynski/README.md index ffabaa7fe..ad8d63bd2 100644 --- a/2004/kopczynski/README.md +++ b/2004/kopczynski/README.md @@ -101,7 +101,7 @@ the number from 8 to 11 that it thinks it is. (`$?` is shorter) * I achieved some additional tightness by `-Dif=while` which saved 9 chars of -source for the cost of 11 chars of the [Makefile](Makefile). If I used +source for the cost of 11 chars of the [Makefile](%%REPO_URL%%/2004/kopczynski/Makefile). If I used `-DB=while`, I would save 12 for 10, but I think the current version is slightly more obfuscated. diff --git a/2004/kopczynski/index.html b/2004/kopczynski/index.html index bab67d382..c496375de 100644 --- a/2004/kopczynski/index.html +++ b/2004/kopczynski/index.html @@ -436,7 +436,7 @@ number, not to print it, but if you think otherwise, the change would cost 6 chars (plus a warning). Change return * to printf("%d",*). ($? is shorter)

  • I achieved some additional tightness by -Dif=while which saved 9 chars of -source for the cost of 11 chars of the Makefile. If I used +source for the cost of 11 chars of the Makefile. If I used -DB=while, I would save 12 for 10, but I think the current version is slightly more obfuscated.

diff --git a/2005/aidan/README.md b/2005/aidan/README.md index 90b3984eb..8b872d19c 100644 --- a/2005/aidan/README.md +++ b/2005/aidan/README.md @@ -58,7 +58,7 @@ more while it puzzles out some puzzles: all in a puzzling way! `goto` the source and notice the lack of functions. Jump to the `switch` statement. And if you think you can puzzle -it out better, try solving [insane1.sudoku](insane1.sudoku) all by yourself! +it out better, try solving [insane1.sudoku](%%REPO_URL%%/2005/aidan/insane1.sudoku) all by yourself! NOTE: the tarball named by the author was removed after the files were extracted into the directory instead. These files were added to the list. @@ -91,7 +91,7 @@ Yes, the test suite really is 5 times larger than the actual program. You ### IMPORTANT -[test.perl](test-su.perl) expects the `sudoku-sf` executable to be +[test.perl](%%REPO_URL%%/2005/aidan/test-su.perl) expects the `sudoku-sf` executable to be `./sudoku-sf`. If you rename it, please change the definition of `$sf_exe` to the new name. @@ -219,7 +219,7 @@ Input should be the numbers of each row in turn. Empty spaces can be represented as a full stop (`.`) or zero (`0`). Other characters are ignored, so you can cut-and-paste either example sudoku puzzle from above into a file and feed that in. The program has coped with every input I've thrown at it so far, including -an [empty grid](blank.sudoku). +an [empty grid](%%REPO_URL%%/2005/aidan/blank.sudoku). Output consists of the problem, then the solution, then a message of success/failure. diff --git a/2005/aidan/index.html b/2005/aidan/index.html index a3516cce7..8e2faef3e 100644 --- a/2005/aidan/index.html +++ b/2005/aidan/index.html @@ -402,7 +402,7 @@ which is slower, inelegant and not as obscure, as the author put it.

more while it puzzles out some puzzles: all in a puzzling way!

goto the source and notice the lack of functions. Jump to the switch statement. And if you think you can puzzle -it out better, try solving insane1.sudoku all by yourself!

+it out better, try solving insane1.sudoku all by yourself!

NOTE: the tarball named by the author was removed after the files were extracted into the directory instead. These files were added to the list.

Author’s remarks:

@@ -425,7 +425,7 @@ generate new ones.

Yes, the test suite really is 5 times larger than the actual program. You did say this was a parody of the software development process…

IMPORTANT

-

test.perl expects the sudoku-sf executable to be +

test.perl expects the sudoku-sf executable to be ./sudoku-sf. If you rename it, please change the definition of $sf_exe to the new name.

Judges’ note: this was done.

@@ -507,7 +507,7 @@ really.

represented as a full stop (.) or zero (0). Other characters are ignored, so you can cut-and-paste either example sudoku puzzle from above into a file and feed that in. The program has coped with every input I’ve thrown at it so far, including -an empty grid.

+an empty grid.

Output consists of the problem, then the solution, then a message of success/failure.

./aidan U may also be useful, or perhaps not. It only took diff --git a/2006/meyer/README.md b/2006/meyer/README.md index 265b4790b..32a0e64f9 100644 --- a/2006/meyer/README.md +++ b/2006/meyer/README.md @@ -37,8 +37,8 @@ NOTE: if your move is invalid it will prompt you again but not show the board. This entry turns a newspaper solitaire puzzle into a competition with the computer to be the last one moving. The object of this -[source code](meyer.c) is to determine the object of this [source -code](meyer.c)! :-) +[source code](%%REPO_URL%%/2006/meyer/meyer.c) is to determine the object of this [source +code](%%REPO_URL%%/2006/meyer/meyer.c)! :-) ## Author's remarks: diff --git a/2006/meyer/index.html b/2006/meyer/index.html index 3e7e8298d..d44a7579e 100644 --- a/2006/meyer/index.html +++ b/2006/meyer/index.html @@ -393,7 +393,7 @@ more text to fulfil the program’s requirements.

Judges’ remarks:

This entry turns a newspaper solitaire puzzle into a competition with the computer to be the last one moving. The object of this -source code is to determine the object of this source +source code is to determine the object of this source code! :-)

Author’s remarks:

I wanted submit a fully object-oriented entry to show that diff --git a/2006/sykes1/README.md b/2006/sykes1/README.md index a40ca40b1..147fffaa0 100644 --- a/2006/sykes1/README.md +++ b/2006/sykes1/README.md @@ -4,7 +4,7 @@ make ``` -There is an alt version based on the author's remarks. The [try.sh](try.sh) +There is an alt version based on the author's remarks. The [try.sh](%%REPO_URL%%/2006/sykes1/try.sh) script will compile and use both but if you wish to see the alternate version specifically see the [Alternate code](#alternate-code) section below. @@ -127,7 +127,7 @@ Some instructions on how to make your own cube are in the included file [bedlam-cubes.pdf](%%REPO_URL%%/2006/sykes1/bedlam-cubes.pdf). Finally, you can watch it being solved with the video file here, -[solving-bedlam-cube.mp4](solving-bedlam-cube.mp4). +[solving-bedlam-cube.mp4](%%REPO_URL%%/2006/sykes1/solving-bedlam-cube.mp4). Actually the cube is very hard to do by hand by just trying to fit it together. I have not known anyone to solve it in this way - you would diff --git a/2006/sykes1/index.html b/2006/sykes1/index.html index 1d9352c67..f4228ac40 100644 --- a/2006/sykes1/index.html +++ b/2006/sykes1/index.html @@ -379,7 +379,7 @@ Location: FI - Republic of Finland

To build:

    make
-

There is an alt version based on the author’s remarks. The try.sh +

There is an alt version based on the author’s remarks. The try.sh script will compile and use both but if you wish to see the alternate version specifically see the Alternate code section below.

Bugs and (Mis)features:

@@ -431,7 +431,7 @@ puzzles in wikipedia.

Some instructions on how to make your own cube are in the included file bedlam-cubes.pdf.

Finally, you can watch it being solved with the video file here, -solving-bedlam-cube.mp4.

+solving-bedlam-cube.mp4.

Actually the cube is very hard to do by hand by just trying to fit it together. I have not known anyone to solve it in this way - you would need to be very lucky indeed to stumble across a solution.

diff --git a/2006/toledo2/README.md b/2006/toledo2/README.md index 9a8c67a7a..0042d36d7 100644 --- a/2006/toledo2/README.md +++ b/2006/toledo2/README.md @@ -102,8 +102,8 @@ and a disk controller, just like at the start of the personal computers revolution (circa 1975). It needs an initial memory image to do something usable, so along with it you -will find two files: ([C.BASIC](C.BASIC) and [C.BIOS](C.BIOS)). Rename -[C.BASIC](C.BASIC) to `C` (NOTE from the judges: running `make` will do this for +will find two files: ([C.BASIC](%%REPO_URL%%/2006/toledo2/C.BASIC) and [C.BIOS](%%REPO_URL%%/2006/toledo2/C.BIOS)). Rename +[C.BASIC](%%REPO_URL%%/2006/toledo2/C.BASIC) to `C` (NOTE from the judges: running `make` will do this for you), run the emulator, and et voila! you have the public domain Palo Alto [Tiny BASIC](https://en.wikipedia.org/wiki/Tiny_BASIC) (by Li-Chen Wang), published in the very first volume of [Dr. Dobb's diff --git a/2006/toledo2/index.html b/2006/toledo2/index.html index 282168dec..e7cd35a87 100644 --- a/2006/toledo2/index.html +++ b/2006/toledo2/index.html @@ -432,8 +432,8 @@ removes those files extracted from the KAYPROII.ZIP.

and a disk controller, just like at the start of the personal computers revolution (circa 1975).

It needs an initial memory image to do something usable, so along with it you -will find two files: (C.BASIC and C.BIOS). Rename -C.BASIC to C (NOTE from the judges: running make will do this for +will find two files: (C.BASIC and C.BIOS). Rename +C.BASIC to C (NOTE from the judges: running make will do this for you), run the emulator, and et voila! you have the public domain Palo Alto Tiny BASIC (by Li-Chen Wang), published in the very first volume of Dr. Dobb’s diff --git a/2011/blakely/README.md b/2011/blakely/README.md index 36d22c598..7e1a4a79f 100644 --- a/2011/blakely/README.md +++ b/2011/blakely/README.md @@ -96,7 +96,7 @@ When evolving forwards, the code can only be stopped by killing the program. In the reverse direction, the code can either be killed, or will stop if it is unable to find a grid that will evolve to the current layout correctly. This can be seen with the sample grid -[t0_3.dat](t0_3.dat), which evolves backwards by only two time-steps. +[t0_3.dat](%%REPO_URL%%/2011/blakely/t0_3.dat), which evolves backwards by only two time-steps. ### Input file format diff --git a/2011/blakely/index.html b/2011/blakely/index.html index 9ed1f8bff..e0e6771b0 100644 --- a/2011/blakely/index.html +++ b/2011/blakely/index.html @@ -428,7 +428,7 @@ line option.

program. In the reverse direction, the code can either be killed, or will stop if it is unable to find a grid that will evolve to the current layout correctly. This can be seen with the sample grid -t0_3.dat, which evolves backwards by only two time-steps.

+t0_3.dat, which evolves backwards by only two time-steps.

Input file format

The input files must encode a square grid, where a space is a dead cell, and any other character (except a newline) is a living cell. Each line must be the same diff --git a/2011/dlowe/README.md b/2011/dlowe/README.md index f8d195824..cd913e454 100644 --- a/2011/dlowe/README.md +++ b/2011/dlowe/README.md @@ -228,11 +228,11 @@ The learning rate is hard-coded as `0.3`. No momentum factor is used. #### png corpora -The [png-1](dlowe-aux-data/png-1) corpus was obtained by manually scraping the first results from an +The `dlowe-aux-data/png-1` corpus was obtained by manually scraping the first results from an search for "[obfuscate filetype:png](https://www.google.com/search?tbm=isch&sxsrf=APwXEddqIU34dxhpFdjEa8emNJKHOkYXIw:1683049158657&source=hp&biw=1727&bih=952&ei=xkpRZLapJtLKkPIP8bGKkAk&iflsig=AOEireoAAAAAZFFY1nbmEUHC74Cmg3Y5rEY1fV7ocASZ&ved=0ahUKEwi2pPXZltf-AhVSJUQIHfGYApIQ4dUDCAY&uact=5&oq=obfuscate+filetype:png&gs_lcp=CgNpbWcQA1AAWABg9QNoAHAAeACAATuIATuSAQExmAEAoAECoAEBqgELZ3dzLXdpei1pbWc&sclient=img&q=obfuscate&tbs=ift:png)". -The [png-0](dlowe-aux-data/png-0) corpus was obtained by manually scraping the first results from an +The `dlowe-aux-data/png-0` corpus was obtained by manually scraping the first results from an search for "[obfuscate filetype:gif](https://www.google.com/search?tbm=isch&ved=2ahUKEwiowo7fltf-AhXSOUQIHbJBDp8Q2-cCegQIABAA&oq=obfuscate+filetype:gif&gs_lcp=CgNpbWcQAzoECCMQJzoHCAAQigUQQzoFCAAQgARQ6AxY6AxgpBJoAHAAeACAAUeIAcsBkgEBM5gBAKABAaoBC2d3cy13aXotaW1nwAEB&sclient=img&ei=0UpRZOiVINLzkPIPsoO5-Ak&bih=952&biw=1727&q=obfuscate&tbs=ift:gif)". @@ -242,7 +242,7 @@ filetype:gif](https://www.google.com/search?tbm=isch&ved=2ahUKEwiowo7fltf-AhXSOU * Using these corpora as a training set; * Using several hundred random `*.gif` and `*.png` files from my home computer as a test set; -* Using the included [earlystop.pl](earlystop.pl) script, which stopped after 67000 iterations. +* Using the included [earlystop.pl](%%REPO_URL%%/2011/dlowe/earlystop.pl) script, which stopped after 67000 iterations. * Interpreting output of `> 0.5` as "probably a `.png`" and `< 0.5` as "probably a `.gif`" @@ -303,7 +303,7 @@ representation and [endianness](https://en.wikipedia.org/wiki/Endianness). Making sure not to [overfit](https://en.wikipedia.org/wiki/Overfitting#Machine_learning) the network to the training data is a bit of a -black art. I have enclosed [earlystop.pl](earlystop.pl), a wrapper script that implements +black art. I have enclosed [earlystop.pl](%%REPO_URL%%/2011/dlowe/earlystop.pl), a wrapper script that implements a simple 'early stopping' algorithm; other techniques are possible. Bad input (e.g. nonexistent files, non-numeric number of iterations, etc.) diff --git a/2011/dlowe/index.html b/2011/dlowe/index.html index bf93dcc3b..47a30ef6b 100644 --- a/2011/dlowe/index.html +++ b/2011/dlowe/index.html @@ -501,10 +501,10 @@ assigned a target value of 0. Intervening directories (if any) will intermediate target values.

The learning rate is hard-coded as 0.3. No momentum factor is used.

png corpora

-

The png-1 corpus was obtained by manually scraping the first results from an +

The dlowe-aux-data/png-1 corpus was obtained by manually scraping the first results from an https://images.google.com search for “obfuscate filetype:png”.

-

The png-0 corpus was obtained by manually scraping the first results from an +

The dlowe-aux-data/png-0 corpus was obtained by manually scraping the first results from an https://images.google.com search for “obfuscate filetype:gif”.

Results:
@@ -512,7 +512,7 @@ filetype:gif”.

  • Using these corpora as a training set;
  • Using several hundred random *.gif and *.png files from my home computer as a test set;
  • -
  • Using the included earlystop.pl script, which stopped after 67000 iterations.
  • +
  • Using the included earlystop.pl script, which stopped after 67000 iterations.
  • Interpreting output of > 0.5 as “probably a .png” and < 0.5 as “probably a .gif”
  • @@ -554,7 +554,7 @@ figuring out how to concatenate directory and file names…).

    representation and endianness.

    Making sure not to overfit the network to the training data is a bit of a -black art. I have enclosed earlystop.pl, a wrapper script that implements +black art. I have enclosed earlystop.pl, a wrapper script that implements a simple ‘early stopping’ algorithm; other techniques are possible.

    Bad input (e.g. nonexistent files, non-numeric number of iterations, etc.) tends to result in empty output.

    diff --git a/2011/hamaji/README.md b/2011/hamaji/README.md index c57ec59af..5dde2423c 100644 --- a/2011/hamaji/README.md +++ b/2011/hamaji/README.md @@ -159,7 +159,7 @@ cannot execute deeper recursions). First of all, as you see, my program looks like a nonogram puzzle which results in a [dragon](https://www.draconika.com/what). This puzzle is -[dragon.nono](dragon.nono) in this directory. Note that whitespaces in character +[dragon.nono](%%REPO_URL%%/2011/hamaji/dragon.nono) in this directory. Note that whitespaces in character literals, a string literal, and around the last comment are considered as a boxed cell. @@ -214,7 +214,7 @@ The second author wrote the picture, and the first author did everything else. The [dragon.nono](%%REPO_URL%%/2011/hamaji/dragon.nono), [samurai.nono](%%REPO_URL%%/2011/hamaji/samurai.nono), and -[penguin.nono](penguin.nono) were written by the +[penguin.nono](%%REPO_URL%%/2011/hamaji/penguin.nono) were written by the second author. The [soccer.nono](%%REPO_URL%%/2011/hamaji/soccer.nono) was from a wikipedia entry. This file is important because it requires some guesses. The [random.nono](%%REPO_URL%%/2011/hamaji/random.nono) file was randomly generated. The [codegolf.nono](%%REPO_URL%%/2011/hamaji/codegolf.nono) and diff --git a/2011/hamaji/index.html b/2011/hamaji/index.html index 1ed0d1486..da210d0ba 100644 --- a/2011/hamaji/index.html +++ b/2011/hamaji/index.html @@ -484,7 +484,7 @@ cannot execute deeper recursions).

    Obfuscation

    First of all, as you see, my program looks like a nonogram puzzle which results in a dragon. This puzzle is -dragon.nono in this directory. Note that whitespaces in character +dragon.nono in this directory. Note that whitespaces in character literals, a string literal, and around the last comment are considered as a boxed cell.

    My program is based on bit operations for speed. Many values are @@ -518,7 +518,7 @@ dragon.

    The second author wrote the picture, and the first author did everything else.

    The dragon.nono, samurai.nono, and -penguin.nono were written by the +penguin.nono were written by the second author. The soccer.nono was from a wikipedia entry. This file is important because it requires some guesses. The random.nono file was randomly generated. The codegolf.nono and diff --git a/2011/toledo/README.md b/2011/toledo/README.md index 9b672e431..c91171a96 100644 --- a/2011/toledo/README.md +++ b/2011/toledo/README.md @@ -8,7 +8,7 @@ If you have X11 installed: There are two alternate versions, [one that lets you reconfigure the controls and size](%%REPO_URL%%/2011/toledo/toledo.alt.c) and [another that should work for -Windows](toledo.alt2.c). See [Alternate code](#alternate-code) below. +Windows](%%REPO_URL%%/2011/toledo/toledo.alt2.c). See [Alternate code](#alternate-code) below. ## To use: diff --git a/2011/toledo/index.html b/2011/toledo/index.html index a74c2d5f4..0dfad5790 100644 --- a/2011/toledo/index.html +++ b/2011/toledo/index.html @@ -381,7 +381,7 @@ Location: MX - United Mexican StatesIf you have X11 installed:

        make

    There are two alternate versions, one that lets you reconfigure the -controls and size and another that should work for +controls and size and another that should work for Windows. See Alternate code below.

    To use:

        ./toledo
    diff --git a/2012/deckmyn/README.md b/2012/deckmyn/README.md index 9d9a19ba7..a16ebfc04 100644 --- a/2012/deckmyn/README.md +++ b/2012/deckmyn/README.md @@ -102,13 +102,13 @@ etc. The program expects *two command line arguments*. The first is a (very long) string that contains the complete music font. Note that it should *not* be given as a file name! The default music font is encoded in the (whitespace of the) -source code [deckmyn.c](deckmyn.c) itself. Therefore, the first argument should +source code [deckmyn.c](%%REPO_URL%%/2012/deckmyn/deckmyn.c) itself. Therefore, the first argument should be `"`` ` ``cat deckmyn.c`` ` ``"`. The second command line argument is the music itself. This is, again, a string, not a file name. All music signs are entered as tokens of exactly 3 characters. The code is very sensitive to bad spacing! So for instance, if you use a file to -write the music (e.g. [example\_greensleeves](example_greensleeves)), you should +write the music (e.g. [example\_greensleeves](%%REPO_URL%%/2012/deckmyn/example_greensleeves)), you should keep in mind that newline is also a character! diff --git a/2012/deckmyn/index.html b/2012/deckmyn/index.html index ffba65f9c..a5565b3bd 100644 --- a/2012/deckmyn/index.html +++ b/2012/deckmyn/index.html @@ -427,12 +427,12 @@ etc.

    The program expects two command line arguments. The first is a (very long) string that contains the complete music font. Note that it should not be given as a file name! The default music font is encoded in the (whitespace of the) -source code deckmyn.c itself. Therefore, the first argument should +source code deckmyn.c itself. Therefore, the first argument should be "`` cat deckmyn.c ``".

    The second command line argument is the music itself. This is, again, a string, not a file name. All music signs are entered as tokens of exactly 3 characters. The code is very sensitive to bad spacing! So for instance, if you use a file to -write the music (e.g. example_greensleeves), you should +write the music (e.g. example_greensleeves), you should keep in mind that newline is also a character!

    Internals

    To minimise the memory footprint, this program has no variable declarations at diff --git a/2012/tromp/README.md b/2012/tromp/README.md index 5b8d9666d..928b6030d 100644 --- a/2012/tromp/README.md +++ b/2012/tromp/README.md @@ -512,7 +512,7 @@ and detract from its single minded focus on conciseness. It implicitly declares functions `read(2)`, `write(2)`, `exit(3)` and `calloc(3)`, the latter two incompatibly. 32 bit and 64 bit executables are -separate [Makefile](Makefile) targets, involving a change from `int` to `long` +separate [Makefile](%%REPO_URL%%/2012/tromp/Makefile) targets, involving a change from `int` to `long` and from a hardcoded sizeof of 4 to 8. The program has been tested to work correctly on Linux/Solaris/MacOSX both in 32 diff --git a/2012/tromp/index.html b/2012/tromp/index.html index 2fd7d3129..c69ca32ef 100644 --- a/2012/tromp/index.html +++ b/2012/tromp/index.html @@ -715,7 +715,7 @@ many warnings;

    and detract from its single minded focus on conciseness.

    It implicitly declares functions read(2), write(2), exit(3) and calloc(3), the latter two incompatibly. 32 bit and 64 bit executables are -separate Makefile targets, involving a change from int to long +separate Makefile targets, involving a change from int to long and from a hardcoded sizeof of 4 to 8.

    The program has been tested to work correctly on Linux/Solaris/MacOSX both in 32 and 64 bits.

    diff --git a/2013/birken/README.md b/2013/birken/README.md index b970a4902..95ef510b2 100644 --- a/2013/birken/README.md +++ b/2013/birken/README.md @@ -333,7 +333,7 @@ rate in which the terminal application receives and displays the [ANSI escape](https://en.wikipedia.org/wiki/ANSI_escape_code) sequences. To slow down the output programmatically, introduce a delay immediately after the -call to `fflush(3)` (N.B: see [birken.alt.c](birken.alt.c)). +call to `fflush(3)` (N.B: see [birken.alt.c](%%REPO_URL%%/2013/birken/birken.alt.c)). ### IOCCC Size Tool Bug diff --git a/2013/birken/index.html b/2013/birken/index.html index 400fe8cdd..37707de7c 100644 --- a/2013/birken/index.html +++ b/2013/birken/index.html @@ -600,7 +600,7 @@ represented using ANSI escape sequences.

    rate in which the terminal application receives and displays the ANSI escape sequences.

    To slow down the output programmatically, introduce a delay immediately after the -call to fflush(3) (N.B: see birken.alt.c).

    +call to fflush(3) (N.B: see birken.alt.c).

    IOCCC Size Tool Bug

    This program demonstrates how to exploit a bug in IOCCC size tool version 2013-07-30-v17. The first line of the program is reproduced below.

    diff --git a/2013/cable3/README.md b/2013/cable3/README.md index cba1d2e13..34ba3a8cb 100644 --- a/2013/cable3/README.md +++ b/2013/cable3/README.md @@ -112,7 +112,7 @@ little endian machine. ### RULE 2 ABUSE DISCLAIMER -- [cable3.c](cable3.c) is 4043 bytes in length (half an 8086). +- [cable3.c](%%REPO_URL%%/2013/cable3/cable3.c) is 4043 bytes in length (half an 8086). - `iocccsize -i < cable3.c` returns 1977 (the year the 4.77 MHz 8086 CPU was announced) - Therefore, any suspicions the judges may have regarding rule 2 non-compliance might be well-intentioned but are groundless. diff --git a/2013/cable3/index.html b/2013/cable3/index.html index de911e65c..4a3331478 100644 --- a/2013/cable3/index.html +++ b/2013/cable3/index.html @@ -445,7 +445,7 @@ and somewhat useless beast. For everyone else, please run the emulator on a little endian machine.

    RULE 2 ABUSE DISCLAIMER

      -
    • cable3.c is 4043 bytes in length (half an 8086).
    • +
    • cable3.c is 4043 bytes in length (half an 8086).
    • iocccsize -i < cable3.c returns 1977 (the year the 4.77 MHz 8086 CPU was announced)
    • Therefore, any suspicions the judges may have regarding rule 2 non-compliance might be well-intentioned but are groundless.
    • diff --git a/2013/dlowe/README.md b/2013/dlowe/README.md index 94070e84d..8b2950293 100644 --- a/2013/dlowe/README.md +++ b/2013/dlowe/README.md @@ -88,7 +88,7 @@ and with Apple clang version 15.0.0 (clang-1500.0.40.1) in 2023, we get: Which one is correct? :) -NOTE: `make all` will compile [fun.c](fun.c) but to provide a different compiler +NOTE: `make all` will compile [fun.c](%%REPO_URL%%/2013/dlowe/fun.c) but to provide a different compiler you can do something like: ``` @@ -113,13 +113,13 @@ A tiny implementation of command-line sparkline of file sizes: ▁▁▁▃▃▂▁▂▁▁▉ ``` -NOTE: this has been provided in [slflen.sh](slflen.sh) so you can try: +NOTE: this has been provided in [slflen.sh](%%REPO_URL%%/2013/dlowe/slflen.sh) so you can try: ``` ./slflen.sh ``` -instead (which [try.sh](try.sh) also uses). +instead (which [try.sh](%%REPO_URL%%/2013/dlowe/try.sh) also uses). ### Description diff --git a/2013/dlowe/index.html b/2013/dlowe/index.html index bfc7a5307..c13bddd05 100644 --- a/2013/dlowe/index.html +++ b/2013/dlowe/index.html @@ -413,7 +413,7 @@ with one argument or when all arguments are equal?

      and with Apple clang version 15.0.0 (clang-1500.0.40.1) in 2023, we get:

          1840985120 -2033041452 35979112

      Which one is correct? :)

      -

      NOTE: make all will compile fun.c but to provide a different compiler +

      NOTE: make all will compile fun.c but to provide a different compiler you can do something like:

          make CC=clang fun

      Author’s remarks:

      @@ -426,9 +426,9 @@ you can do something like:

      $ echo "sparkline of file lengths: $(wc -c * | awk '{print $1}' | xargs ./sparkl)" sparkline of file sizes: ▁▁▁▃▃▂▁▂▁▁▉
      -

      NOTE: this has been provided in slflen.sh so you can try:

      +

      NOTE: this has been provided in slflen.sh so you can try:

          ./slflen.sh
      -

      instead (which try.sh also uses).

      +

      instead (which try.sh also uses).

      Description

      This is a handy little tool for visualizing numeric series from the command line, using sparklines. Pass it a numeric series as arguments, and diff --git a/2013/endoh4/README.md b/2013/endoh4/README.md index 229ca0125..769500e20 100644 --- a/2013/endoh4/README.md +++ b/2013/endoh4/README.md @@ -142,7 +142,7 @@ So, try: ./endoh4 < endoh4.c # or ./endoh4.sh ``` -The [solids/](solids/) directory includes various solid data: +The `solids` directory includes various solid data: - [Platonic solids](http://en.wikipedia.org/wiki/Platonic_solid) - [Archimedean solids](http://en.wikipedia.org/wiki/Archimedean_solid) diff --git a/2013/endoh4/index.html b/2013/endoh4/index.html index 38b7f34e7..6c5a96277 100644 --- a/2013/endoh4/index.html +++ b/2013/endoh4/index.html @@ -451,7 +451,7 @@ clang, and tcc. It should not trigger warnings with -pedantic and <

      The shape of this code is the geometric net of a regular tetrahedron. So, try:

          ./endoh4 < endoh4.c # or ./endoh4.sh
      -

      The solids/ directory includes various solid data:

      +

      The solids directory includes various solid data:

      • Platonic solids
      • Archimedean solids
      • diff --git a/2013/hou/README.md b/2013/hou/README.md index 196918d8f..c7e8f235b 100644 --- a/2013/hou/README.md +++ b/2013/hou/README.md @@ -1,4 +1,4 @@ -## To build: +%%REPO_URL%%/## To build: ``` make all @@ -137,7 +137,7 @@ don't have to worry about conflicts. * [hou.c](%%REPO_URL%%/2013/hou/hou.c) uses compression to get around the size limit. The compression fully complies with the rules and the guidelines (at least the portion that shows up in `grep` "size limit"). Please see the [Self-imposed -restrictions](self-imposed-restrictions) section below for more details. +restrictions](#self-imposed-restrictions) section below for more details. * `hou` does not terminate (as suggested by the second line of rule 6). diff --git a/2013/hou/doc/example.html b/2013/hou/doc/example.html index a84639a56..c29f7465f 100644 --- a/2013/hou/doc/example.html +++ b/2013/hou/doc/example.html @@ -587,7 +587,7 @@ editing program, you need to convert the RGB values from 0..255 to 0..1, and then put here its square. Only after squaring you get your real, lively color in the output image, as opposed to something dull and gray. You need to do the same if you use a RGB texture. And yes, that is the what the second sqrt(3) in -a.c is for.

        +a.c is for.

        Going beyond colors, to define a shiny or dull surface one needs more maths, and optics. The jargon for this is BRDF (Bidirectional Reflectance Distribution Function) importance sampling. Let’s continue to function o.

        diff --git a/2013/hou/doc/example.md b/2013/hou/doc/example.md index 000aef2cd..f927e9b18 100644 --- a/2013/hou/doc/example.md +++ b/2013/hou/doc/example.md @@ -312,7 +312,7 @@ editing program, you need to convert the RGB values from 0..255 to 0..1, and then put here its *square*. Only after squaring you get your real, lively color in the output image, as opposed to something dull and gray. You need to do the same if you use a RGB texture. And yes, that is the what the second `sqrt(3)` in -[a.c](../a.c) is for. +[a.c](%%REPO_URL%%/2013/hou/a.c) is for. Going beyond colors, to define a shiny or dull surface one needs more maths, and optics. The jargon for this is `BRDF` (Bidirectional Reflectance Distribution diff --git a/2013/hou/index.html b/2013/hou/index.html index 15552d34d..dabba6300 100644 --- a/2013/hou/index.html +++ b/2013/hou/index.html @@ -377,7 +377,7 @@ Location: CN - People’s Republic of C -

        To build:

        +

        https://github.com/ioccc-src/temp-test-ioccc/blob/master/## To build:

            make all

        Bugs and (Mis)features:

        The current status of this entry is:

        @@ -468,7 +468,7 @@ don’t have to worry about conflicts. diff --git a/2014/skeggs/README.md b/2014/skeggs/README.md index 32f8a1942..b03b5e8b5 100644 --- a/2014/skeggs/README.md +++ b/2014/skeggs/README.md @@ -60,7 +60,7 @@ Escape to quit.) Unfortunately, it became very difficult to get this entry to fit within the size requirements. It's currently at 2052 according to -[iocccsize](../iocccsize.c), and 3994 according to `wc -c`. +[iocccsize](%%REPO_URL%%/2014/iocccsize.c), and 3994 according to `wc -c`. The current size is a third to a half of the original size before compression. diff --git a/2014/skeggs/index.html b/2014/skeggs/index.html index e49dcf09b..8f64fca50 100644 --- a/2014/skeggs/index.html +++ b/2014/skeggs/index.html @@ -414,7 +414,7 @@ Escape to quit.)

        KNOWN COMPILER WARNINGS

        Unfortunately, it became very difficult to get this entry to fit within the size requirements. It’s currently at 2052 according to -iocccsize, and 3994 according to wc -c.

        +iocccsize, and 3994 according to wc -c.

        The current size is a third to a half of the original size before compression.

        Due to this, it does LOTS of things that subtly annoy compilers!

          diff --git a/2015/README.md b/2015/README.md index ea9680a6b..be33c2870 100644 --- a/2015/README.md +++ b/2015/README.md @@ -46,7 +46,7 @@ We suggest that you attempt to completely understand the [endoh4](endoh4/index.html) 1-liner program: another impressive compact piece of C code. -And while you are at it, cat the [endoh2 prog.c](endoh2/prog.c) code. Compile it +And while you are at it, cat the [endoh2 prog.c](%%REPO_URL%%/2015/endoh2/prog.c) code. Compile it and look at the source code again. In a "Back to the Future" moment, [endoh3](endoh3/index.html) gave us a twist on @@ -77,7 +77,7 @@ Rule 22, now known as **Catch 22** states: to be Peter Honeyman, will be grounds for disqualification of your entry. ``` -A number of other entries were based on [iocccsize.c](iocccsize.c), making +A number of other entries were based on [iocccsize.c](%%REPO_URL%%/2015/iocccsize.c), making derivative works rather than original works. Still other entries were too large, violating the first line of rule 2: diff --git a/2015/burton/README.md b/2015/burton/README.md index cc4e3c1ae..8262e0eda 100644 --- a/2015/burton/README.md +++ b/2015/burton/README.md @@ -122,7 +122,7 @@ Flow control is by `for` and `return`. It is `if`-less, `switch`-less, `while`-less, and hopeless. Literally, if not figuratively. ;-) The code size is intentionally 2015, as stated by `iocccsize -i`, and can be -reformatted without changes (as in [rule2.c](rule2.c)) to exactly 4096 octets. +reformatted without changes (as in [rule2.c](%%REPO_URL%%/2015/burton/rule2.c)) to exactly 4096 octets. Finally, `calc` is interesting, if for no other reason than it is practically useful: Hex/decimal conversion, arithmetic, byte-swapping, bit-shifting, and diff --git a/2015/burton/index.html b/2015/burton/index.html index a56ba62ab..c421f19bc 100644 --- a/2015/burton/index.html +++ b/2015/burton/index.html @@ -434,7 +434,7 @@ and hex input.

          Flow control is by for and return. It is if-less, switch-less, while-less, and hopeless. Literally, if not figuratively. ;-)

          The code size is intentionally 2015, as stated by iocccsize -i, and can be -reformatted without changes (as in rule2.c) to exactly 4096 octets.

          +reformatted without changes (as in rule2.c) to exactly 4096 octets.

          Finally, calc is interesting, if for no other reason than it is practically useful: Hex/decimal conversion, arithmetic, byte-swapping, bit-shifting, and logical operations with memory, on the command line, or interactively.

          diff --git a/2015/duble/README.md b/2015/duble/README.md index 00298a82a..fc35c72b1 100644 --- a/2015/duble/README.md +++ b/2015/duble/README.md @@ -69,12 +69,12 @@ wondering if it was not the reason for its very erratic behaviour. ### [prog.c](%%REPO_URL%%/2015/duble/prog.c) vs [prog.alt.c](%%REPO_URL%%/2015/duble/prog.alt.c) -The file [prog.alt.c](prog.alt.c) is the one I submitted. +The file [prog.alt.c](%%REPO_URL%%/2015/duble/prog.alt.c) is the one I submitted. [Gil Dogon](../../authors.html#Gil_Dogon) noted a few unsafe statements (statements whose behaviour is undefined in the C standard and, as such, could cause issues with other compilers or optimization levels). These have been fixed in -[prog.c](prog.c). +[prog.c](%%REPO_URL%%/2015/duble/prog.c). After this fix, in order to remain rule-2-compliant, a variable name has also been shortened in this file. diff --git a/2015/duble/index.html b/2015/duble/index.html index 487ecd199..38e7c3fc3 100644 --- a/2015/duble/index.html +++ b/2015/duble/index.html @@ -409,11 +409,11 @@ allows to consider each terminal character as a tiny 2x4 bitmap.

          blasphemous. When I was fighting to make this program work, I started wondering if it was not the reason for its very erratic behaviour.

          prog.c vs prog.alt.c

          -

          The file prog.alt.c is the one I submitted.

          +

          The file prog.alt.c is the one I submitted.

          Gil Dogon noted a few unsafe statements (statements whose behaviour is undefined in the C standard and, as such, could cause issues with other compilers or optimization levels). These have been fixed in -prog.c.

          +prog.c.

          After this fix, in order to remain rule-2-compliant, a variable name has also been shortened in this file.

          How to build

          diff --git a/2015/endoh1/README.md b/2015/endoh1/README.md index 29bba5e68..0d1d70faf 100644 --- a/2015/endoh1/README.md +++ b/2015/endoh1/README.md @@ -134,7 +134,9 @@ All cells have `(u0, v0)` by default. You can specify a pattern file when the executable is invoked (not compile-time). The file should include a sequence of points, see -[ioccc.txt](ioccc.txt), [center.txt](center.txt), or [line.txt](line.txt) as +[ioccc.txt](%%REPO_URL%%/2015/endoh1/ioccc.txt), +[center.txt](%%REPO_URL%%/2015/endoh1/center.txt), +or [line.txt](%%REPO_URL%%/2015/endoh1/line.txt) as examples. Each amount in cells near to the point included in the file, will be added by `(u1, v1)`. diff --git a/2015/endoh1/index.html b/2015/endoh1/index.html index 1e895bb8e..0e0f4bfbc 100644 --- a/2015/endoh1/index.html +++ b/2015/endoh1/index.html @@ -461,7 +461,9 @@ notation.

          All cells have (u0, v0) by default.

          You can specify a pattern file when the executable is invoked (not compile-time). The file should include a sequence of points, see -ioccc.txt, center.txt, or line.txt as +ioccc.txt, +center.txt, +or line.txt as examples. Each amount in cells near to the point included in the file, will be added by (u1, v1).

          Simulation speed: -DTIMESTEP=ts -DSPEED=spd

          diff --git a/2015/endoh3/README.md b/2015/endoh3/README.md index 258b55f1b..eb1980091 100644 --- a/2015/endoh3/README.md +++ b/2015/endoh3/README.md @@ -87,7 +87,7 @@ hijack the `main()` function call. And then it interprets `main()` as an instruction sequence. It supports the minimal subset of instructions and addressing modes which are -needed for [mullender.c](mullender.c) to work: +needed for [mullender.c](%%REPO_URL%%/2015/endoh3/mullender.c) to work: * Instructions * BR: branch diff --git a/2015/endoh3/index.html b/2015/endoh3/index.html index 7c511dfd9..05e89a2cd 100644 --- a/2015/endoh3/index.html +++ b/2015/endoh3/index.html @@ -427,7 +427,7 @@ Read it upside down.)

          hijack the main() function call. And then it interprets main() as an instruction sequence.

          It supports the minimal subset of instructions and addressing modes which are -needed for mullender.c to work:

          +needed for mullender.c to work:

          • Instructions
              diff --git a/2015/index.html b/2015/index.html index 47c050095..4b89ed621 100644 --- a/2015/index.html +++ b/2015/index.html @@ -394,7 +394,7 @@ particularly enjoy this entry.

              We suggest that you attempt to completely understand the endoh4 1-liner program: another impressive compact piece of C code.

              -

              And while you are at it, cat the endoh2 prog.c code. Compile it +

              And while you are at it, cat the endoh2 prog.c code. Compile it and look at the source code again.

              In a “Back to the Future” moment, endoh3 gave us a twist on one of the all time best IOCCC entries from 1984.

              @@ -414,7 +414,7 @@ and 22 (one third of 666).

              Identifying yourself, in an obvious way in your code, data, remarks or program output, unless you are Peter Honeyman or pretending to be Peter Honeyman, will be grounds for disqualification of your entry. -

              A number of other entries were based on iocccsize.c, making +

              A number of other entries were based on iocccsize.c, making derivative works rather than original works.

              Still other entries were too large, violating the first line of rule 2:

                  2) The size of your program source must be <= 4096 bytes in length.
              diff --git a/2018/README.md b/2018/README.md index a76c892f6..0856f6aa4 100644 --- a/2018/README.md +++ b/2018/README.md @@ -74,7 +74,7 @@ Rule 22, now known as "Catch 22" states: to be Peter Honeyman, will be grounds for disqualification of your entry. ``` -A number of other entries were based on [iocccsize.c](iocccsize.c), making +A number of other entries were based on [iocccsize.c](%%REPO_URL%%/2018/iocccsize.c), making derivative works rather than original works. Still other entries were too large, violating the first line of rule 2: diff --git a/2018/burton2/README.md b/2018/burton2/README.md index 438ee386e..33f9a6fe2 100644 --- a/2018/burton2/README.md +++ b/2018/burton2/README.md @@ -158,7 +158,7 @@ These test cases were vital in debugging and regression testing, and provided a determine which tool was correct when there were differences. ``` - A version of this tool in more clearly written C ([tac.c](tac.c)) + A version of this tool in more clearly written C is presented for the Judge's consideration as a more accurate replacement for `iocccsize`. This obfuscated entry is derived from (and compatible with) that code, but due to obfuscation, has had some significant, deep changes for the contest. @@ -166,10 +166,10 @@ determine which tool was correct when there were differences. ``` NB: `iocccsize` gets a different answer from `tac` on its own -([iocccsize.c](../../2018/iocccsize.c)) source code; +([iocccsize.c](%%REPO_URL%%/2018/iocccsize.c)) source code; `tac` gets the correct answer. This is due to the aforementioned bugs within `iocccsize`, proved by fixing -[iocccsize.c](../../2018/iocccsize.c) with the included patch, so `iocccsize` reports +[iocccsize.c](%%REPO_URL%%/2018/iocccsize.c) with the included patch, so `iocccsize` reports the correct answer for itself. ### But wait... There's More! @@ -219,7 +219,7 @@ This allows such additional programs in concert with the tool's primary operatio A poor-man's de-obfuscator can be based upon the output of `tac -t` and a handful of simple rules (and another use of the external keyword file). A more -refined version of this is included in the file [unob.sh](unob.sh), but the +refined version of this is included in the file [unob.sh](%%REPO_URL%%/2018/burton/unob.sh), but the simple code below is a serviceable obfuscated C de-obfuscator in a _scripting language_. It really is this easy with `tac`: @@ -294,7 +294,7 @@ language_. It really is this easy with `tac`: * The code describes its function by careful arrangement of variables up front... * ...coupled with a description of the typical IOCCC contestant, or at least the author * Why shouldn't trigraph parsing be written in trigraph? -* Where [iocccsize.c](../../2018/iocccsize.c) mocks, this code flaunts: +* Where [iocccsize.c](%%REPO_URL%%/2018/iocccsize.c) mocks, this code flaunts: "_no matter how well you may think you understand this code, you don't, so don't mess with it. :-)_" * `O,0,l,1` are used to confusing effect, local names obscure global names. * Globals are used to pass information between routines: don't reorder "unrelated" statements.... @@ -316,7 +316,7 @@ using a different list. For instance: removing all the secondary keywords; removing all the C11 keywords; trying just K&R C. Since C++ and Java share the same operators as C, just change the keyword list and `tac` will correctly tokenize both of these; the tokens `>>>` and `::` can be handled with a short -post-filter ([tokenfix.sh](tokenfix.sh), included). +post-filter ([tokenfix.sh](%%REPO_URL%%/2018/burton2/tokenfix.sh), included). I believe this entry may also satisfy the request for gratuitous use of all the C11 keywords? Whether this context satisfies "intended C language context" is a @@ -326,20 +326,20 @@ the IOJCC trash can. The following reserved word files are included: -* [kandr](kandr) from my venerable 1978 18th printing "The C Programming Language" -* [v7unix](v7unix) 7th edition Unix source code, extracted from c00.c -* [kandr2](kandr2) from my 1988 1st printing "The C Programming Language", 2e -* [ansi](ansi) ANSI X3.159-1989 -* [c99](c99) ISO/IEC 9899:1999(E) -* [c11](c11) ISO/IEC 9899:201x(E) N1570 -* [c++98](c++98) http://en.cppreference.com/w/cpp/keyword -* [c++11](c++11) ISO/IEC 14882:2011(E) N3337 2012-01-16 -* [c++14](c++14) ISO/IEC 14882:2014(E) N4296 2014-11-09 -* [java8](java8) -* [ioccc.kw.freq](ioccc.kw.freq) c11 + additional words, sorted on frequency of occurrence in IOCCC entries +* [kandr](%%REPO_URL%%/2018/burton/kandr) from my venerable 1978 18th printing "The C Programming Language" +* [v7unix](%%REPO_URL%%/2018/burton/v7unix) 7th edition Unix source code, extracted from c00.c +* [kandr2](%%REPO_URL%%/2018/burton/kandr2) from my 1988 1st printing "The C Programming Language", 2e +* [ansi](%%REPO_URL%%/2018/burton/ansi) ANSI X3.159-1989 +* [c99](%%REPO_URL%%/2018/burton/c99) ISO/IEC 9899:1999(E) +* [c11](%%REPO_URL%%/2018/burton/c11) ISO/IEC 9899:201x(E) N1570 +* [c++98](%%REPO_URL%%/2018/burton/c++98) http://en.cppreference.com/w/cpp/keyword +* [c++11](%%REPO_URL%%/2018/burton/c++11) ISO/IEC 14882:2011(E) N3337 2012-01-16 +* [c++14](%%REPO_URL%%/2018/burton/c++14) ISO/IEC 14882:2014(E) N4296 2014-11-09 +* [java8](%%REPO_URL%%/2018/burton/java8) +* [ioccc.kw.freq](%%REPO_URL%%/2018/burton/ioccc.kw.freq) c11 + additional words, sorted on frequency of occurrence in IOCCC entries -NB: The keyword file used in this code is derived from the list in [iocccsize.c](../../2018/iocccsize.c), +NB: The keyword file used in this code is derived from the list in [iocccsize.c](%%REPO_URL%%/2018/iocccsize.c), which is neither complete (`#define`, `#ifndef`, `#undef` are missing ``` @@ -396,12 +396,13 @@ Thus: ### Coda: [Cody Boone Ferguson](../../authors.html#Cody_Boone_Ferguson) was relentless in his pursuit of bugs. -Thanks to his reports, the version of [unob.sh](unob.sh) is stronger, -`tac` groks digraphs, [tokenfix.sh](tokenfix.sh) corrects for missing digraphs -in [prog.c](prog.c), and the program [manpage.sh](manpage.sh) was added to the corpus. +Thanks to his reports, the version of [unob.sh](%%REPO_URL%%/2018/burton2/unob.sh) is stronger, +`tac` groks digraphs, [tokenfix.sh](%%REPO_URL%%/2018/burton2/tokenfix.sh) corrects for missing digraphs +in [prog.c](%%REPO_URL%%/2018/burton/prog.c), and the program +[manpage.sh](%%REPO_URL%%/2018/burton/manpage.sh) was added to the corpus. -[manpage.sh](manpage.sh) is a useful program that turns ASCII versions of man -pages (e.g. [tac.man](tac.man)) into real man pages. It works for C and C-like +[manpage.sh](%%REPO_URL%%/2018/burton/manpage.sh) is a useful program that turns ASCII versions of man +pages (e.g. [tac.man](%%REPO_URL%%/2018/burton/tac.man)) into real man pages. It works for C and C-like languages, command lines, and was designed to handle man page sections 1-8. It works well on most inputs, but tends to need some raw nroff for more fancy constructions, such as combined arguments (e.g. the `-r` and `-s` arguments to tac @@ -419,7 +420,7 @@ Try: ``` NOTE: in 2023 the `tac.man` was updated to proper man format and renamed -[tac.1](tac.1). +[tac.1](%%REPO_URL%%/2018/burton/tac.1). @@ -103,7 +103,7 @@ You can also try other programs from the Web. Many example programs are in the o entries from [quine contest][4]. There is an alternative build path that requires the 2018 IOCCC size tool to complete. Put the tool -source [iocccsize_2018.c](iocccsize_2018.c) in the project directory and call +source [iocccsize_2018.c](%%REPO_URL%%/2019/adamovskyiocccsize_2018.c) in the project directory and call ``` make identify @@ -199,7 +199,7 @@ since it was developed using `char`s it should be always used safely. ### Spoilers: -- You can examine the [progSpoiler.c](progSpoiler.c) file. It is the original +- You can examine the [progSpoiler.c](%%REPO_URL%%/2019/adamovskyprogSpoiler.c) file. It is the original final version of the interpreter, before I started the downsizing. It accepts one more optional parameter that specifies a filename for the output Unlambda function (it's the Unlambda function that remains after all function @@ -291,7 +291,7 @@ be applied. [6]: https://en.wikipedia.org/wiki/Lambda_calculus "Lambda Calculus on Wikipedia" [7]: https://en.wikipedia.org/wiki/Combinatory_logic "Combinatory Logic on Wikipedia" [8]: https://inazz.jp/unlambda/ "Online Unlambda interpreter" -[9]: ../../2014/birken/index.html "Best use of port 1701" +[9]: %%REPO_URL%%/2014/birken/index.html "Best use of port 1701" @@ -92,7 +92,7 @@ All your base belong to us, but the constants seem a bit ... off? ### Bonus -The script [cow.sh](cow.sh) provides a closer analog, and perhaps a more useful +The script [cow.sh](%%REPO_URL%%/2019/burton/cow.sh) provides a closer analog, and perhaps a more useful interface. Included is a version without compilation warnings: diff --git a/2019/burton/index.html b/2019/burton/index.html index 149d3a600..f944b9b10 100644 --- a/2019/burton/index.html +++ b/2019/burton/index.html @@ -405,7 +405,7 @@ The output should look familiar.

              Description:

              Included is a test script, useful for the corner cases. As in all good Unix programs, it is silent upon success; any output demonstrates an error. Instead -of checking correctness, the check.sh script can simply output the +of checking correctness, the check.sh script can simply output the results: (The Makefile contains the spoiler):

                  out=cat ./check.sh ./prog

              Interestingly, and a spoiler here: macOS and FreeBSD implement the common @@ -423,7 +423,7 @@ Input should be less than ten million octets “toavoidthisproblem”.

              No whitespace was harmed in the creation of this program. All your base belong to us, but the constants seem a bit … off?

              Bonus

              -

              The script cow.sh provides a closer analog, and perhaps a more useful +

              The script cow.sh provides a closer analog, and perhaps a more useful interface.

              Included is a version without compilation warnings:

                  cc -Wall -Wextra -Weverything -pedantic -include stdio.h -o prog.clean prog.clean.c
              diff --git a/2019/ciura/README.md b/2019/ciura/README.md index e1b421393..8b43d5ade 100644 --- a/2019/ciura/README.md +++ b/2019/ciura/README.md @@ -132,14 +132,14 @@ is too long, and 2 if the command-line arguments are missing. ### Helper scripts: -- [getwords.sh](getwords.sh) +- [getwords.sh](%%REPO_URL%%/2019/ciura/getwords.sh) `./getwords.sh LANGUAGE_CODE` outputs a sorted list of unique words in a given language, one per line. It requires `aspell` with a dictionary for _LANGUAGE_CODE_. -- [wrapprog.py](wrapprog.py) +- [wrapprog.py](%%REPO_URL%%/2019/ciura/wrapprog.py) `./wrapprog.py LETTERS [N]` @@ -148,8 +148,9 @@ is too long, and 2 if the command-line arguments are missing. it finishes the job faster than `prog` when there are millions of perfect pangrams. It requires a UTF-8 locale. -- [de.sh](de.sh), [en.sh](en.sh), [fr.sh](fr.sh), [it.sh](it.sh), -[pl.sh](pl.sh), and [ru.sh](ru.sh) output German, +- [de.sh](%%REPO_URL%%/2019/ciura/de.sh), [en.sh](%%REPO_URL%%/2019/ciura/en.sh), +[fr.sh](%%REPO_URL%%/2019/ciura/fr.sh), [it.sh](%%REPO_URL%%/2019/ciura/it.sh), +[pl.sh](%%REPO_URL%%/2019/ciura/pl.sh), and [ru.sh](%%REPO_URL%%/2019/ciura/ru.sh) output German, English, French, Italian, Polish, and Russian perfect pangrams, respectively. They require a UTF-8 locale. @@ -162,7 +163,7 @@ among the programs that won IOCCC in the past), and _obscure bugs_ (see the questions about Linux core dumps below). To a casual eye, this entry may look similar to -[2005/klausler](../../2005/klausler/index.html). +[2005/klausler](%%REPO_URL%%/2005/klausler/index.html). However, `prog` is internationalized and way faster. On my machine, `./klausler abcdefghijklmnopqrstuvwxyz` printed only 3,965 perfect pangrams until I killed it after 144 hours running, while the @@ -173,7 +174,7 @@ the example from section [What is this?](#wit) finished in 1.35 seconds. On the other hand, `prog` can only output series of words with non-repeating characters, unlike `klausler`. -In contrast to [prog.alt.c](prog.alt.c), [prog.c](prog.c) does not call +In contrast to [prog.alt.c](%%REPO_URL%%/2019/ciura/prog.alt.c), [prog.c](%%REPO_URL%%/2019/ciura/prog.c) does not call `fflush(stdout)` after outputting each line, thus running faster. I am grateful to Witold Jarnicki for suggesting this change. The original `prog` finished the example above in 100 minutes @@ -201,8 +202,8 @@ by without `goto M` and `goto H`, I challenge the adherents of structured programming to refactor `goto T`, which jumps back into a nested `if` block. -With the supplied [Makefile](Makefile), both `gcc` and `clang` compile -[prog.c](prog.c) without warnings in C11 and C99 mode. For a clean +With the supplied [Makefile](%%REPO_URL%%/2019/ciura/Makefile), both `gcc` and `clang` compile +[prog.c](%%REPO_URL%%/2019/ciura/prog.c) without warnings in C11 and C99 mode. For a clean compilation with `gcc -std=c90`, add `-Wno-format` to `CSILENCE` in `Makefile`. diff --git a/2019/ciura/index.html b/2019/ciura/index.html index 7b5ce6fa3..4eb2f9788 100644 --- a/2019/ciura/index.html +++ b/2019/ciura/index.html @@ -451,18 +451,19 @@ unlimited. The characters in LETTERS must not repeat. The length of is too long, and 2 if the command-line arguments are missing.

              Helper scripts:

                -
              • getwords.sh

                +
              • getwords.sh

                ./getwords.sh LANGUAGE_CODE

                outputs a sorted list of unique words in a given language, one per line. It requires aspell with a dictionary for LANGUAGE_CODE.

              • -
              • wrapprog.py

                +
              • wrapprog.py

                ./wrapprog.py LETTERS [N]

                works similarly to ./prog LETTERS [N] except that it merges pangrams before passing them to prog and expands them in prog’s output. This way, it finishes the job faster than prog when there are millions of perfect pangrams. It requires a UTF-8 locale.

              • -
              • de.sh, en.sh, fr.sh, it.sh, -pl.sh, and ru.sh output German, +

              • de.sh, en.sh, +fr.sh, it.sh, +pl.sh, and ru.sh output German, English, French, Italian, Polish, and Russian perfect pangrams, respectively. They require a UTF-8 locale.

              @@ -472,7 +473,7 @@ They require a UTF-8 locale.

              among the programs that won IOCCC in the past), and obscure bugs (see the questions about Linux core dumps below).

              To a casual eye, this entry may look similar to -2005/klausler. +2005/klausler. However, prog is internationalized and way faster. On my machine, ./klausler abcdefghijklmnopqrstuvwxyz printed only 3,965 perfect pangrams until I killed it after 144 hours running, while the @@ -482,7 +483,7 @@ finished in 62 minutes, reporting 1,640,569,315 perfect pangrams, and the example from section What is this? finished in 1.35 seconds. On the other hand, prog can only output series of words with non-repeating characters, unlike klausler.

              -

              In contrast to prog.alt.c, prog.c does not call +

              In contrast to prog.alt.c, prog.c does not call fflush(stdout) after outputting each line, thus running faster. I am grateful to Witold Jarnicki for suggesting this change. The original prog finished the example above in 100 minutes @@ -504,8 +505,8 @@ have no perfect pangrams.

              by without goto M and goto H, I challenge the adherents of structured programming to refactor goto T, which jumps back into a nested if block.

              -

              With the supplied Makefile, both gcc and clang compile -prog.c without warnings in C11 and C99 mode. For a clean +

              With the supplied Makefile, both gcc and clang compile +prog.c without warnings in C11 and C99 mode. For a clean compilation with gcc -std=c90, add -Wno-format to CSILENCE in Makefile.

              make @@ -35,8 +35,8 @@ the program and the script. ## Judges' remarks: -[1991/davidguy](../../1991/davidguy/index.html), -[2011/blakely](../../2011/blakely/index.html), ... +[1991/davidguy](%%REPO_URL%%/1991/davidguy/index.html), +[2011/blakely](%%REPO_URL%%/2011/blakely/index.html), ... ...This entry likely concludes the IOCCC category "Cellular automata simulators"; it would be very hard to beat it on its field. @@ -135,7 +135,7 @@ is the current macrocell (`L`) and which zoom Scale you are watching (`S`). This entry is quite portable hopefully on most modern platforms. It assumes X Window support of course. More than 2GB of memory is recommended. Configuration -through [Makefile](Makefile) is provided for the display windows size and for +through [Makefile](%%REPO_URL%%/2019/dogon/Makefile) is provided for the display windows size and for the memory usage. The Makefile provided configuration (`Z=0x20000000`) will need a system with 4GB DRAM to run nicely. There are several other salient assumptions though: @@ -228,7 +228,7 @@ includes some famous name dropping and documents itself as usual. ### Further spoilers, engineering, and obfuscation galore: Those wait for you, curious and intrepid reader, in the attached -[apholife.c](apholife.c) file, which is a partially obfuscated version of the +[apholife.c](%%REPO_URL%%/2019/ciura/apholife.c) file, which is a partially obfuscated version of the program I wrote with a lot of helpful annotations and comments for myself and posterity, revealing some of the magic under the hood. This program is also a somewhat improved version which uses `ldexp()`s in the draw routine and has diff --git a/2019/dogon/index.html b/2019/dogon/index.html index 8474ab1fb..68c952032 100644 --- a/2019/dogon/index.html +++ b/2019/dogon/index.html @@ -377,7 +377,7 @@ Location: IL - State of Israel ( -

              To build:

              +

              https://github.com/ioccc-src/temp-test-ioccc/blob/master/2019/lynn/## To build:

                  make

              Bugs and (Mis)features:

              The current status of this entry is:

              @@ -390,8 +390,8 @@ Location: IL - State of Israel (Make sure that you keep focus of windows in mind when going back and forth to the program and the script.

              Judges’ remarks:

              -

              1991/davidguy, -2011/blakely, …

              +

              1991/davidguy, +2011/blakely, …

              …This entry likely concludes the IOCCC category “Cellular automata simulators”; it would be very hard to beat it on its field.

              FYI: The .mc extension stands for Golly macrocell format.

              @@ -469,7 +469,7 @@ is the current macrocell (L) and which zoom Scale you are watching

              Portability issues

              This entry is quite portable hopefully on most modern platforms. It assumes X Window support of course. More than 2GB of memory is recommended. Configuration -through Makefile is provided for the display windows size and for +through Makefile is provided for the display windows size and for the memory usage. The Makefile provided configuration (Z=0x20000000) will need a system with 4GB DRAM to run nicely. There are several other salient assumptions though:

              @@ -543,7 +543,7 @@ character juxtaposed against a very ancient one, not to mention the program includes some famous name dropping and documents itself as usual.

              Further spoilers, engineering, and obfuscation galore:

              Those wait for you, curious and intrepid reader, in the attached -apholife.c file, which is a partially obfuscated version of the +apholife.c file, which is a partially obfuscated version of the program I wrote with a lot of helpful annotations and comments for myself and posterity, revealing some of the magic under the hood. This program is also a somewhat improved version which uses ldexp()s in the draw routine and has diff --git a/2019/duble/README.md b/2019/duble/README.md index 74ff128ac..a1731308e 100644 --- a/2019/duble/README.md +++ b/2019/duble/README.md @@ -91,7 +91,7 @@ directory which you'll have to delete manually. This is also discussed in ## Alternate code: -An alternate version of this entry, [prog.alt.c](prog.alt.c), is provided. This +An alternate version of this entry, [prog.alt.c](%%REPO_URL%%/2019/duble/prog.alt.c), is provided. This alternate code might not work as well in macOS. @@ -228,9 +228,9 @@ IMPORTANT NOTES: so any peer reaching the session should have a terminal with the same size or larger. -### [prog.c](prog.c) vs [prog.alt.c](prog.alt.c) +### [prog.c](%%REPO_URL%%/2019/duble/prog.c) vs [prog.alt.c](%%REPO_URL%%/2019/duble/prog.alt.c) -The file [prog.alt.c](prog.alt.c) is the one I submitted. +The file [prog.alt.c](%%REPO_URL%%/2019/duble/prog.alt.c) is the one I submitted. The judges proposed a small update: the program was using macro `FD_SET` inside an expression, which breaks compilation on macOS. Wrapping this macro into a @@ -240,13 +240,13 @@ However, that was not enough to make the program work on macOS. If you analyse the program you will see that it heavily relies on OS resources. And, for this first version of the program, you even needed to increase default `sysctl` parameters to make it work on FreeBSD (this was the purpose of file -[check-os.sh](check-os.sh)). I tried hard to tune macOS the same, but failed. +[check-os.sh](%%REPO_URL%%/2019/duble/check-os.sh)). I tried hard to tune macOS the same, but failed. The simple fact the Judges proposed this update meant they wish it could work on Mac. And if the judges wish something, it **has to** be done. ;) So I refactored a little more the program to reduce OS resources consumption. Or maybe not reduce consumption, but consume them differently... And I obtained -[prog.c](prog.c). With this version, no need to touch `sysctl` parameters, and +[prog.c](%%REPO_URL%%/2019/duble/prog.c). With this version, no need to touch `sysctl` parameters, and it works on macOS too! I must confess it was challenging to remain below the size limit with this little change. diff --git a/2019/duble/index.html b/2019/duble/index.html index 5a57e6f35..beb7e5e63 100644 --- a/2019/duble/index.html +++ b/2019/duble/index.html @@ -422,7 +422,7 @@ in the beginning this will also happen. This is discussed in directory which you’ll have to delete manually. This is also discussed in 2019 duble bugs.

              Alternate code:

              -

              An alternate version of this entry, prog.alt.c, is provided. This +

              An alternate version of this entry, prog.alt.c, is provided. This alternate code might not work as well in macOS.

              Alternate build:

                  make alt
              @@ -510,8 +510,8 @@ with a different size!
              so any peer reaching the session should have a terminal with the same size or larger.
            -

            prog.c vs prog.alt.c

            -

            The file prog.alt.c is the one I submitted.

            +

            prog.c vs prog.alt.c

            +

            The file prog.alt.c is the one I submitted.

            The judges proposed a small update: the program was using macro FD_SET inside an expression, which breaks compilation on macOS. Wrapping this macro into a function was enough to fix this compilation issue.

            @@ -519,12 +519,12 @@ function was enough to fix this compilation issue.

            the program you will see that it heavily relies on OS resources. And, for this first version of the program, you even needed to increase default sysctl parameters to make it work on FreeBSD (this was the purpose of file -check-os.sh). I tried hard to tune macOS the same, but failed.

            +check-os.sh). I tried hard to tune macOS the same, but failed.

            The simple fact the Judges proposed this update meant they wish it could work on Mac. And if the judges wish something, it has to be done. ;) So I refactored a little more the program to reduce OS resources consumption. Or maybe not reduce consumption, but consume them differently… And I obtained -prog.c. With this version, no need to touch sysctl parameters, and +prog.c. With this version, no need to touch sysctl parameters, and it works on macOS too! I must confess it was challenging to remain below the size limit with this little change.

            (./prog < fib.hs ; cat prog.c) > fib.c @@ -78,7 +78,8 @@ Test the compiler on [fib.hs](fib.hs): Compiling the output produces a binary that prints the 30th Fibonacci number. -The file [ghcfib.hs](ghcfib.hs) includes [fib.hs](fib.hs) with some glue code, +The file [ghcfib.hs](%%REPO_URL%%/2019/lynn/ghcfib.hs) +includes [fib.hs](%%REPO_URL%%/2019/lynn/fib.hs) with some glue code, and shows GHC also accepts our subset of Haskell: ``` @@ -89,7 +90,7 @@ and shows GHC also accepts our subset of Haskell: #### Self-hosting compiler: To avoid spoiling this entry by revealing the original Haskell source, we -instead provide [hint.hs](hint.hs), the output of a certain stage of the +instead provide [hint.hs](%%REPO_URL%%/2019/lynn/hint.hs), the output of a certain stage of the compiler when run on itself. This intermediate output is hopefully difficult to understand, yet is accepted by our compiler: @@ -102,7 +103,7 @@ understand, yet is accepted by our compiler: The output program behaves like the compiler itself. Unlike the original source from which it is derived, GHC fails to compile -[hint.hs](hint.hs). This is because values have been replaced with their [Scott +[hint.hs](%%REPO_URL%%/2019/lynn/hint.hs). This is because values have been replaced with their [Scott encodings](https://en.wikipedia.org/wiki/Mogensen-Scott_encoding) by this stage, which messes up type-checks; we'd need `equirecursive` types for it to work. @@ -110,7 +111,7 @@ it to work. #### Regexes: -The file [lol.hs](lol.hs) contains an adaptation of [Doug McIlroy's elegant code from +The file [lol.hs](%%REPO_URL%%/2019/lynn/lol.hs) contains an adaptation of [Doug McIlroy's elegant code from "Enumerating the strings of regular languages"](https://www.cs.dartmouth.edu/~doug/nfa.pdf). We exercise it by showing the first entries of the length-ordered list of all strings consisting @@ -131,7 +132,7 @@ A GHC wrapper is provided: ### Strongly-connected components: -See [scc.hs](scc.hs) (and its GHC wrapper [ghcscc.hs](ghcscc.hs)) for an elegant +See [scc.hs](%%REPO_URL%%/2019/lynn/scc.hs) (and its GHC wrapper [ghcscc.hs](%%REPO_URL%%/2019/lynn/ghcscc.hs)) for an elegant way to print the strongly-connected components of a graph in reverse topological order. @@ -280,7 +281,7 @@ represent the integer `n` with a term equivalent to `Y(BT)n`; it works because * A sentinel in the heap often confused me, so ought to confuse others. Other obfuscation techniques are better appreciated after decoding the -compiler. See [hint.hs](hint.hs). +compiler. See [hint.hs](%%REPO_URL%%/2019/lynn/hint.hs). * Mercilessly point-free. Everything is a combinator. * Scott encoding. Everything is a combinator. diff --git a/2019/lynn/index.html b/2019/lynn/index.html index 0bd511b28..2ca3e23a2 100644 --- a/2019/lynn/index.html +++ b/2019/lynn/index.html @@ -411,15 +411,16 @@ trace of those scary unsafeThisAndThat functions. All functions mus
                cc -o prog prog.c

            Demos:

            Fibonacci numbers:

            -

            Test the compiler on fib.hs:

            +

            Test the compiler on fib.hs:

                (./prog < fib.hs ; cat prog.c) > fib.c

            Compiling the output produces a binary that prints the 30th Fibonacci number.

            -

            The file ghcfib.hs includes fib.hs with some glue code, +

            The file ghcfib.hs +includes fib.hs with some glue code, and shows GHC also accepts our subset of Haskell:

                ghc ghcfib.hs

            Self-hosting compiler:

            To avoid spoiling this entry by revealing the original Haskell source, we -instead provide hint.hs, the output of a certain stage of the +instead provide hint.hs, the output of a certain stage of the compiler when run on itself. This intermediate output is hopefully difficult to understand, yet is accepted by our compiler:

                (./prog < hint.hs ; cat prog.c) > hint.c
            @@ -427,12 +428,12 @@ understand, yet is accepted by our compiler:

            ./hint

            The output program behaves like the compiler itself.

            Unlike the original source from which it is derived, GHC fails to compile -hint.hs. This is because values have been replaced with their Scott +hint.hs. This is because values have been replaced with their Scott encodings by this stage, which messes up type-checks; we’d need equirecursive types for it to work.

            Regexes:

            -

            The file lol.hs contains an adaptation of Doug McIlroy’s elegant code from +

            The file lol.hs contains an adaptation of Doug McIlroy’s elegant code from “Enumerating the strings of regular languages”. We exercise it by showing the first entries of the length-ordered list of all strings consisting @@ -443,7 +444,7 @@ of the characters a and b that contain an even number

            A GHC wrapper is provided:

                ghc ghclol.hs

            Strongly-connected components:

            -

            See scc.hs (and its GHC wrapper ghcscc.hs) for an elegant +

            See scc.hs (and its GHC wrapper ghcscc.hs) for an elegant way to print the strongly-connected components of a graph in reverse topological order.

                (./prog < scc.hs ; cat prog.c) > scc.c
            @@ -547,7 +548,7 @@ represent the integer n with a term equivalent to Y(BT)nA sentinel in the heap often confused me, so ought to confuse others.

          Other obfuscation techniques are better appreciated after decoding the -compiler. See hint.hs.

          +compiler. See hint.hs.

          • Mercilessly point-free. Everything is a combinator.
          • Scott encoding. Everything is a combinator.
          • diff --git a/2019/poikola/README.md b/2019/poikola/README.md index da6b9f684..c0c0c3558 100644 --- a/2019/poikola/README.md +++ b/2019/poikola/README.md @@ -162,7 +162,7 @@ White](https://www.glyphweb.com/arda/g/gandalf.html) and the [Judges of the IOCCC](../../judges.html). Output of `iocccsize`, using the [2019 version of -iocccsize](../../2019/iocccsize.c), is carefully selected. For +iocccsize](%%REPO_URL%%/2019/iocccsize.c), is carefully selected. For the sake of clarity, I used single letter variables in the code. I also avoided unnecessary use of functions. Like a [tripundra](https://en.wikipedia.org/wiki/Tripundra), this program has three @@ -261,7 +261,7 @@ arrays, so I did it. [Cody Boone Ferguson](../../authors.html#Cody_Boone_Ferguson): I really like that you enjoyed my previous entry. I hope that you will like this entry too. Because I did not want to give too many clues to [the Judges](../../judges.html), I tried to write this -entry in a different way than [Most Stellar](../../2018/poikola/index.html), but in this +entry in a different way than [Most Stellar](%%REPO_URL%%/2018/poikola/index.html), but in this code there is at least one recycled thing from it. By the way, the answers to the questions I posed: (1) 255. (2) Try to compare binary representations of those `float`s and binary representation of the string "`25th IOCCC!`". (3) I @@ -278,7 +278,7 @@ not match anymore and `goto` jumps to the end of the code. I see that one of the [Volker Diels-Grabsch](../../authors.html#Volker_Diels-Grabsch)'s winning entries is -awarded the category [Most self-aware](../../2019/diels-grabsch2/prog.c). In last +awarded the category [Most self-aware](%%REPO_URL%%/2019/diels-grabsch2/prog.c). In last year, my entry incorporates the [Fletcher's 16 algorithm](https://en.wikipedia.org/wiki/Fletcher%27s_checksum#Fletcher-16) to ensure integrity of code. One of my first ideas for this year was to do the same diff --git a/2019/poikola/index.html b/2019/poikola/index.html index d113d0e64..4c95955a0 100644 --- a/2019/poikola/index.html +++ b/2019/poikola/index.html @@ -454,7 +454,7 @@ who passed away on fourth of February 2019.

            So, I followed the rules given by Gandalf the White and the Judges of the IOCCC.

            -

            Output of iocccsize, using the 2019 version of +

            Output of iocccsize, using the 2019 version of iocccsize, is carefully selected. For the sake of clarity, I used single letter variables in the code. I also avoided unnecessary use of functions. Like a @@ -521,7 +521,7 @@ arrays, so I did it.

            Cody Boone Ferguson: I really like that you enjoyed my previous entry. I hope that you will like this entry too. Because I did not want to give too many clues to the Judges, I tried to write this -entry in a different way than Most Stellar, but in this +entry in a different way than Most Stellar, but in this code there is at least one recycled thing from it. By the way, the answers to the questions I posed: (1) 255. (2) Try to compare binary representations of those floats and binary representation of the string “25th IOCCC!”. (3) I @@ -537,7 +537,7 @@ checksum does not match anymore and goto jumps to the end of the code.

            I see that one of the Volker Diels-Grabsch’s winning entries is -awarded the category Most self-aware. In last +awarded the category Most self-aware. In last year, my entry incorporates the Fletcher’s 16 algorithm to ensure integrity of code. One of my first ideas for this year was to do the same diff --git a/2019/yang/README.md b/2019/yang/README.md index 14f69463b..a6be85f9c 100644 --- a/2019/yang/README.md +++ b/2019/yang/README.md @@ -209,7 +209,7 @@ Verified to work and compiles without warnings on these environments: I tried really hard to make `prog.c` fit in a 80x25 terminal without wrapping. If I were not constrained by space, I would have made an ASCII art out of it. -[violet.c](violet.c) is that program, and also comes with the minor benefit of +[violet.c](%%REPO_URL%%/2019/yang/violet.c) is that program, and also comes with the minor benefit of supporting lines longer than a million columns depending on `sizeof(int)`. Violet is named after [Violet diff --git a/2019/yang/index.html b/2019/yang/index.html index 68633fd83..3b050e14e 100644 --- a/2019/yang/index.html +++ b/2019/yang/index.html @@ -496,7 +496,7 @@ feeds (preserved) and tabs (expanded to 8 spaces).

            Full version

            I tried really hard to make prog.c fit in a 80x25 terminal without wrapping. If I were not constrained by space, I would have made an ASCII art out of it. -violet.c is that program, and also comes with the minor benefit of +violet.c is that program, and also comes with the minor benefit of supporting lines longer than a million columns depending on sizeof(int).

            Violet is named after Violet Evergarden in the story with diff --git a/2020/burton/README.md b/2020/burton/README.md index 7945aef1e..c696c54fc 100644 --- a/2020/burton/README.md +++ b/2020/burton/README.md @@ -80,7 +80,7 @@ transformation occurs. ### Rule 2-ish: -Exporting the constants `B`,`I`,`T`,`S` to the [Makefile](Makefile) allows the +Exporting the constants `B`,`I`,`T`,`S` to the [Makefile](%%REPO_URL%%/2020/burton/Makefile) allows the code to be compiled for either LE (little-endian) or BE (big-endian) machines(!!), so they are truly configuration parameters, not logic. diff --git a/2020/burton/index.html b/2020/burton/index.html index 60f093dec..2da6ddedc 100644 --- a/2020/burton/index.html +++ b/2020/burton/index.html @@ -412,7 +412,7 @@ result?

            Invoke this with a single non-negative integer less than 256, and a useful transformation occurs.

            Rule 2-ish:

            -

            Exporting the constants B,I,T,S to the Makefile allows the +

            Exporting the constants B,I,T,S to the Makefile allows the code to be compiled for either LE (little-endian) or BE (big-endian) machines(!!), so they are truly configuration parameters, not logic.

            Notes:

            diff --git a/2020/endoh1/README.md b/2020/endoh1/README.md index 0c5dbbc47..6a525da45 100644 --- a/2020/endoh1/README.md +++ b/2020/endoh1/README.md @@ -34,7 +34,7 @@ code](#alternate-code) below. ## Alternate code: -An alternate version of this entry, [prog.alt.c](prog.alt.c), is provided. This +An alternate version of this entry, [prog.alt.c](%%REPO_URL%%/2020/endoh1/prog.alt.c), is provided. This alternate code lacks the additional rule to flag all unprobed cells. See the Author's remarks for more details. @@ -217,13 +217,13 @@ There are mines in a cell whose "priorities-of-each-cell" is less than ### Bug fixes and Credits The judges pointed out a bug of the original version that I submitted -([prog.alt.c](prog.alt.c)). Because this program does not provide a feature to +([prog.alt.c](%%REPO_URL%%/2020/endoh1/prog.alt.c)). Because this program does not provide a feature to flag unprobed cells manually, we can do nothing if the number of unprobed cells are equal to the number of mines remaining; [unwinnable.txt](unwinnable.txt) is an example for such a case. Thus, I implemented an additional rule to flag all unprobed cells in such a case -into the final version ([prog.c](prog.c)). +into the final version ([prog.c](%%REPO_URL%%/2020/endoh1/prog.c)). [Ilya Kurdyukov](../../authors.html#Ilya_Kurdyukov) also pointed out a warning "ignoring return value of 'fscanf'" only when `-O3` is used. So I changed the diff --git a/2020/endoh1/index.html b/2020/endoh1/index.html index 95d7197ee..7d3f6cd37 100644 --- a/2020/endoh1/index.html +++ b/2020/endoh1/index.html @@ -396,7 +396,7 @@ code below.

            ./prog unwinnable.txt

            Alternate code:

            -

            An alternate version of this entry, prog.alt.c, is provided. This +

            An alternate version of this entry, prog.alt.c, is provided. This alternate code lacks the additional rule to flag all unprobed cells. See the Author’s remarks for more details.

            Alternate build:

            @@ -499,12 +499,12 @@ Analyze the code.

            “number-of-mines”. (But the mine in the first-clicked cell is removed.)

            Bug fixes and Credits

            The judges pointed out a bug of the original version that I submitted -(prog.alt.c). Because this program does not provide a feature to +(prog.alt.c). Because this program does not provide a feature to flag unprobed cells manually, we can do nothing if the number of unprobed cells are equal to the number of mines remaining; unwinnable.txt is an example for such a case.

            Thus, I implemented an additional rule to flag all unprobed cells in such a case -into the final version (prog.c).

            +into the final version (prog.c).

            Ilya Kurdyukov also pointed out a warning “ignoring return value of ‘fscanf’” only when -O3 is used. So I changed the code a little to pretend to use the return value of fscanf(3).

            diff --git a/2020/endoh2/README.md b/2020/endoh2/README.md index 0804aac84..6a1f4ab08 100644 --- a/2020/endoh2/README.md +++ b/2020/endoh2/README.md @@ -29,11 +29,11 @@ What happens if you do ## Judges' remarks: -Clever use of the C99 complex data type. The [spoiler](spoiler/) directory +Clever use of the C99 complex data type. The [spoiler](%%REPO_URL%%/2020/endoh2/spoiler/spoiler.html) directory contains clues as to how some winning authors create / edit programs into ASCII shapes. -With the source from the [spoiler](spoiler/) directory could you make the code +With the source from the [spoiler](%%REPO_URL%%/2020/endoh2/spoiler/spoiler.html) directory could you make the code render for a larger terminal window? How about adding more glyphs? diff --git a/2020/endoh2/index.html b/2020/endoh2/index.html index f1626c142..911f210f3 100644 --- a/2020/endoh2/index.html +++ b/2020/endoh2/index.html @@ -387,10 +387,10 @@ Location: JP - Japan
                ./prog prog.c

            ?

            Judges’ remarks:

            -

            Clever use of the C99 complex data type. The spoiler directory +

            Clever use of the C99 complex data type. The spoiler directory contains clues as to how some winning authors create / edit programs into ASCII shapes.

            -

            With the source from the spoiler directory could you make the code +

            With the source from the spoiler directory could you make the code render for a larger terminal window? How about adding more glyphs?

            Author’s remarks:

            No! Try not. Do, or do not. There is no try.

            diff --git a/2020/endoh3/README.md b/2020/endoh3/README.md index f091a3d26..7036e2411 100644 --- a/2020/endoh3/README.md +++ b/2020/endoh3/README.md @@ -25,7 +25,7 @@ code](#alternate-code) below. ## Alternate code: -An alternate version of this entry, [prog.alt.c](prog.alt.c), is provided. This +An alternate version of this entry, [prog.alt.c](%%REPO_URL%%/2020/endoh3/prog.alt.c), is provided. This alternate code uses Unicode letters. @@ -55,7 +55,7 @@ You may be tempted to use a mirror. Resist the temptation! Try figuring out how the clock hands are drawn. Can you change the program to make it draw a familiar (non-mirrored) clock face? Can you add the second hand? -When using the [run_clock.sh](run_clock.sh) shell script, your perception of +When using the [run_clock.sh](%%REPO_URL%%/2020/endoh3/run_clock.sh) shell script, your perception of time might depend on what time it is. diff --git a/2020/endoh3/index.html b/2020/endoh3/index.html index 098622999..0d39acea9 100644 --- a/2020/endoh3/index.html +++ b/2020/endoh3/index.html @@ -387,7 +387,7 @@ code below.

                ./run_clock
                 # And watch closely for 15-20 seconds

            Alternate code:

            -

            An alternate version of this entry, prog.alt.c, is provided. This +

            An alternate version of this entry, prog.alt.c, is provided. This alternate code uses Unicode letters.

            Alternate build:

                make alt
            @@ -400,7 +400,7 @@ alternate code uses Unicode letters.

            You may be tempted to use a mirror. Resist the temptation! Try figuring out how the clock hands are drawn. Can you change the program to make it draw a familiar (non-mirrored) clock face? Can you add the second hand?

            -

            When using the run_clock.sh shell script, your perception of +

            When using the run_clock.sh shell script, your perception of time might depend on what time it is.

            Author’s remarks:

            Prepare a mirror!

            diff --git a/2020/ferguson1/README.md b/2020/ferguson1/README.md index 19849ff9e..cd2ce19ee 100644 --- a/2020/ferguson1/README.md +++ b/2020/ferguson1/README.md @@ -60,7 +60,7 @@ and non-zero). size to grow every time you eat a bug. Default 5; negative values are allowed. 'Negativity' creates for fun gameplay modes with enough creativity. See [gameplay.html](gameplay.html) - GitHub) as well as [play.sh](play.sh) for some examples. + GitHub) as well as [play.sh](%%REPO_URL%%/2020/ferguson1/play.sh) for some examples. * **SHED**
            every **SHED** movements you will grow (> 0), shrink (< 0) or @@ -76,7 +76,7 @@ and non-zero). you can create some fun gameplay modes here. For instance you can grow upon eating a bug but shrink every **SHED** movements and then it's a battle of whether you win by **SIZE < 0** or - **SIZE >= MAXSIZE**. See [play.sh](play.sh) for examples. + **SIZE >= MAXSIZE**. See [play.sh](%%REPO_URL%%/2020/ferguson1/play.sh) for examples. NOTE: the concept of shedding in this game is a misnomer; see notes below. @@ -516,13 +516,13 @@ been warned. I submitted three Snake versions; these are the other layouts for those few (more likely none) who are interested to see them. -The [prog.2.c](prog.2.c) has more digraphs but I think no other significant differences. +The [prog.2.c](%%REPO_URL%%/2020/ferguson1/prog.2.c) has more digraphs but I think no other significant differences. -The [prog.3.c](prog.3.c) is in a more artistic layout (a backwards S), has at least one +The [prog.3.c](%%REPO_URL%%/2020/ferguson1/prog.3.c) is in a more artistic layout (a backwards S), has at least one additional obfuscation technique (see spoilers) but it also has more digraphs and as the judges said they feel that digraphs are dated so that's probably why -they chose the first layout. The [prog.3-j.c](prog.3-j.c) version is -[prog.3.c](prog.3.c) with a shorter `J` macro. +they chose the first layout. The [prog.3-j.c](%%REPO_URL%%/2020/ferguson1/prog.3-j.c) version is +[prog.3.c](%%REPO_URL%%%%REPO_URL%%//2020/ferguson1/prog.3.c) with a shorter `J` macro. The prog.alt.c version is the one that allows for customising the bug colour and it's used in both [snake-colours.sh][] and [play.sh][]. It also calls `erase()` @@ -544,7 +544,7 @@ but Don Yang and Edward Giles too. But there are some others who I don't remember like [Ilya Kurdyukov](../../authors.html#Ilya_Kurdyukov) -(who's offered a lot of interesting thoughts on [Snake](../ferguson1/prog.c) and +(who's offered a lot of interesting thoughts on [Snake](%%REPO_URL%%/2020/ferguson1/prog.c) and who plans to have his own version after the entries are published), [Nathan Otterness](../../authors.html#Nathan_Otterness), [Nicholas Carlini](../../authors.html#Nicholas_Carlini) (your entry is an absolutely brilliant @@ -556,7 +556,7 @@ Well done and congratulations to all of you again! Thank you for submitting the wonderful entries and I'm honoured to have my two entries beside yours! To Dave Burton I thank you for your wonderful comments as well as pointing out -that even with [prog.alt.c](prog.alt.c) it probably would be better to make use +that even with [prog.alt.c](%%REPO_URL%%/2020/ferguson1/prog.alt.c) it probably would be better to make use of the alt target instead of naming prog.c prog.alt.c. You're quite right, I had thought of it but you brought it up so I could correct it. Much appreciated mate. diff --git a/2020/ferguson1/index.html b/2020/ferguson1/index.html index 9e21f80b9..e0027fde4 100644 --- a/2020/ferguson1/index.html +++ b/2020/ferguson1/index.html @@ -417,7 +417,7 @@ MAXSIZE you win before you grow to the full size!

            size to grow every time you eat a bug. Default 5; negative values are allowed. ‘Negativity’ creates for fun gameplay modes with enough creativity. See gameplay.html -GitHub) as well as play.sh for some examples.

            +GitHub) as well as play.sh for some examples.

          • SHED
            every SHED movements you will grow (> 0), shrink (< 0) or stay the same length (0) by the SHEDS (below) value. Again @@ -431,7 +431,7 @@ eats a bug the counter isn’t incremented. Again with creativity you can create some fun gameplay modes here. For instance you can grow upon eating a bug but shrink every SHED movements and then it’s a battle of whether you win by SIZE < 0 or -SIZE >= MAXSIZE. See play.sh for examples. +SIZE >= MAXSIZE. See play.sh for examples. NOTE: the concept of shedding in this game is a misnomer; see notes below.

          • CANNIBAL
            @@ -793,12 +793,12 @@ been warned.

          • I submitted three Snake versions; these are the other layouts for those few (more likely none) who are interested to see them.

            -

            The prog.2.c has more digraphs but I think no other significant differences.

            -

            The prog.3.c is in a more artistic layout (a backwards S), has at least one +

            The prog.2.c has more digraphs but I think no other significant differences.

            +

            The prog.3.c is in a more artistic layout (a backwards S), has at least one additional obfuscation technique (see spoilers) but it also has more digraphs and as the judges said they feel that digraphs are dated so that’s probably why -they chose the first layout. The prog.3-j.c version is -prog.3.c with a shorter J macro.

            +they chose the first layout. The prog.3-j.c version is +prog.3.c with a shorter J macro.

            The prog.alt.c version is the one that allows for customising the bug colour and it’s used in both snake-colours.sh and play.sh. It also calls erase() first, clearing the screen, which the play.sh and snake-colours.sh scripts also @@ -815,7 +815,7 @@ programmers. I’m especially proud to win besides Dave Burton and Yusuke Endoh but Don Yang and Edward Giles too.

            But there are some others who I don’t remember like Ilya Kurdyukov -(who’s offered a lot of interesting thoughts on Snake and +(who’s offered a lot of interesting thoughts on Snake and who plans to have his own version after the entries are published), Nathan Otterness, Nicholas Carlini (your entry is an absolutely brilliant @@ -825,7 +825,7 @@ list!) and tsoj too.

            Well done and congratulations to all of you again! Thank you for submitting the wonderful entries and I’m honoured to have my two entries beside yours!

            To Dave Burton I thank you for your wonderful comments as well as pointing out -that even with prog.alt.c it probably would be better to make use +that even with prog.alt.c it probably would be better to make use of the alt target instead of naming prog.c prog.alt.c. You’re quite right, I had thought of it but you brought it up so I could correct it. Much appreciated mate.

            diff --git a/2020/ferguson2/README.md b/2020/ferguson2/README.md index 02f68776a..f4c85090c 100644 --- a/2020/ferguson2/README.md +++ b/2020/ferguson2/README.md @@ -1,4 +1,4 @@ -## To build: +%%REPO_URL%%/## To build: ``` make @@ -43,7 +43,7 @@ at once. See [Alternate code](#alternate-code) below. ./recode -v ``` -**NOTE**: in [recode](recode.c) no spaces between options and option arguments +**NOTE**: in [recode](%%REPO_URL%%/2020/ferguson2/recode.c) no spaces between options and option arguments are allowed. @@ -65,7 +65,7 @@ do? ## Alternate code: -This version, [prog.alt.c](prog.alt.c), writes a character at a time, sleeping +This version, [prog.alt.c](%%REPO_URL%%/2020/ferguson2/prog.alt.c), writes a character at a time, sleeping after each character, so that one can read it more easily (for longer output) and to make it a bit more like the real thing. @@ -107,7 +107,7 @@ This code is an [enigma](https://youtu.be/ybkkiGtJmkM). Try to decode it! There is a good deal of useful documentation that is provided with this entry: -* [enigma.1](enigma.1) - A useful man page for this entry. To render, try: +* [enigma.1](%%REPO_URL%%/2020/ferguson2/enigma.1) - A useful man page for this entry. To render, try: ``` @@ -116,7 +116,7 @@ There is a good deal of useful documentation that is provided with this entry: * [recode.html][] (or [recode.html](recode.html) if reading on GitHub) - - Some useful information about [recode.c](recode.c) + - Some useful information about [recode.c](%%REPO_URL%%/2020/ferguson2/recode.c) * [chocolate-cake.html][] (or [chocolate-cake.html](chocolate-cake.html) if reading on GitHub) @@ -131,7 +131,7 @@ There is a good deal of useful documentation that is provided with this entry: ## Author's remarks: My remarks about my [Heer][] (army) and [Luftwaffe][] (air force) [Enigma -machine](https://www.cryptomuseum.com/crypto/enigma/index.htm) [simulator](prog.c) for +machine](https://www.cryptomuseum.com/crypto/enigma/index.htm) [simulator](%%REPO_URL%%/2020/ferguson2/prog.c) for the 27th IOCCC. I want to dedicate this entry in part to the millions of poor souls that were @@ -405,7 +405,7 @@ Phew! The program redeemed itself after the test failure! :) is with some of the things I pasted in the other file and maybe others here too. Notice also how it showed the same output that my program gave it - `UUMMX`.) -What about the other [Morse code entry](../../1998/dorssel/dorssel.c)? +What about the other [Morse code entry](%%REPO_URL%%/1998/dorssel/dorssel.c)? ``` $ echo IOCCC | ./prog | ./dorssel @@ -433,7 +433,7 @@ It has a randomise mode and it can save/read the settings to/from a file to allow for duplicity (an archaic term for the state of being double but obviously for Enigma it has to also mean deceitful). -I recommend using this in a pipeline instead of the [simulator](prog.c) itself +I recommend using this in a pipeline instead of the [simulator](%%REPO_URL%%/2020/ferguson2/prog.c) itself if you want to change the configuration of the simulator because it offers a much richer experience (and because you can reuse the configuration without having to type it out again every time). @@ -453,7 +453,7 @@ For examples using it (and a delicious challenge) see [recode.html][] (or The parser is in a sense rather rudimentary but allows for both interactive and -automatic (e.g. via the [recode](recode.c) program) input. This does mean that +automatic (e.g. via the [recode]((%%REPO_URL%%/2020/ferguson2recode.c) program) input. This does mean that something like the following can happen: ``` @@ -499,7 +499,7 @@ is buffering at play I believe but it's useful for allowing the `recode` program to easily configure the Enigma machine. In the [recode.html](recode.html) file (or [recode.html](recode.html) if reading on GitHub) file I give a hint as to how this could be fixed but the caveat is it would necessitate a need for rewriting -[recode.c](recode.c). +[recode.c](%%REPO_URL%%/2020/ferguson2/recode.c). There's another thing to be aware of and that's the way the ranges are enforced. There are five rotors which obviously are in C 0-4 but in 'natural language' @@ -508,7 +508,7 @@ There are five rotors which obviously are in C 0-4 but in 'natural language' There are two [reflectors](https://www.ciphermachinesandcryptology.com/en/enigmatech.htm#Reflector) and the same applies: in C 0-1 but in human it's 1-2 (technically these were reflectors B and C in -the Enigma machine which I display by name in [recode.c](recode.c) just like +the Enigma machine which I display by name in [recode.c](%%REPO_URL%%/2020/ferguson2/recode.c) just like with the rotors). For more information see [recode.html][] (or [recode.html](recode.html) if viewing on @@ -531,7 +531,7 @@ accomplished and made use of! :) The layout of [recode.c][] isn't too significant (but see below) but I want to -mention [prog.c](prog.c) especially: +mention [prog.c](%%REPO_URL%%/2020/ferguson2/prog.c) especially: I did think of a more artistic layout but [reflecting](https://www.ciphermachinesandcryptology.com/en/enigmatech.htm#Reflector) @@ -587,7 +587,7 @@ The file [obfuscation.key][] is the key to decipher/encipher For the lazy [obfuscation.html](obfuscation.html) has the deciphered version. I am afraid I'm not so inclined to do that for the cake recipe: the idea there is to make it a fun exercise that when solved unlocks a wonderful double-layered chocolate fudge -cake recipe. But given that my ['Don't tread on me'](../ferguson1) award entry +cake recipe. But given that my ['Don't tread on me'](../ferguson1/index.html) award entry also has the [recipe](../ferguson1/chocolate-cake.html) ([ferguson1/chocolate-cake.html](../ferguson1/chocolate-cake.html) if reading on GitHub), not enciphered, one might just go there instead. Still it's a fun way @@ -639,7 +639,7 @@ can at least have the output played in Morse code as the Germans did; I think that's really cool (I think it's really cool even if there's a bug in it). That it pays homage to that (and another) entry is a bonus here. -* The [simulator](prog.c) doesn't report errors but tries to gracefully deal +* The [simulator](%%REPO_URL%%/2020/ferguson2/prog.c) doesn't report errors but tries to gracefully deal with them: if one chooses a value out of range it moves it into the range (if > the max then the max, if < min then the min). If invalid chars are input for the plugboard pairs then it's not added to the plugboard etc. @@ -798,7 +798,7 @@ rotor selection 'screen'. Then use the arrow buttons above each rotor to set from left to right B, B and C. After this you can type your message in the input field and watch the wiring of the rotors change and show the path it takes. -If I made use of the Enigma code in the [recode.c](recode.c) program I would +If I made use of the Enigma code in the [recode.c](%%REPO_URL%%/2020/ferguson2/recode.c) program I would maybe consider doing something like that but I intentionally do not use it there: as cool as it might be it would give a better idea of how the algorithm works (unless I were to make it just as obscure as I do in prog.c but that's @@ -886,7 +886,7 @@ but Don Yang and Edward Giles too. But there are some others who I don't remember like [Ilya Kurdyukov](../../authors.html#Ilya_Kurdyukov) -(who's offered a lot of interesting thoughts on [Snake](../ferguson1/prog.c) and +(who's offered a lot of interesting thoughts on [Snake](%%REPO_URL%%/2020/ferguson1/prog.c) and who plans to have his own version after the entries are published), [Nathan Otterness](../../authors.html#Nathan_Otterness), [Nicholas Carlini](../../authors.html#Nicholas_Carlini) (your entry is an absolutely brilliant diff --git a/2020/ferguson2/index.html b/2020/ferguson2/index.html index 9d956696c..5e6f4463e 100644 --- a/2020/ferguson2/index.html +++ b/2020/ferguson2/index.html @@ -377,7 +377,7 @@ Location: US - United States of America -

            To build:

            +

            https://github.com/ioccc-src/temp-test-ioccc/blob/master/## To build:

                make

            The author provided alternate code that prints the output one character at a time to make it a bit more like the real thing in that it isn’t dumped out all @@ -412,7 +412,7 @@ at once. See Alternate code below.

            # show Enigma machine settings after selection / generation: ./recode -v -

            NOTE: in recode no spaces between options and option arguments +

            NOTE: in recode no spaces between options and option arguments are allowed.

            Try:

                ./try.sh
            @@ -421,7 +421,7 @@ are allowed.

            echo | ./recode -v

            do?

            Alternate code:

            -

            This version, prog.alt.c, writes a character at a time, sleeping +

            This version, prog.alt.c, writes a character at a time, sleeping after each character, so that one can read it more easily (for longer output) and to make it a bit more like the real thing.

            Alternate build:

            @@ -440,13 +440,13 @@ out! Can you figure out why this works this way?

            This code is an enigma. Try to decode it!

            There is a good deal of useful documentation that is provided with this entry:

              -
            • enigma.1 - A useful man page for this entry. To render, try:
            • +
            • enigma.1 - A useful man page for this entry. To render, try:
                man ./enigma.1
            • recode.html (or recode.html if reading on GitHub)
                -
              • Some useful information about recode.c
              • +
              • Some useful information about recode.c
            • chocolate-cake.html (or chocolate-cake.html if reading on GitHub)
                @@ -456,7 +456,7 @@ out! Can you figure out why this works this way?

              Author’s remarks:

              My remarks about my Heer (army) and Luftwaffe (air force) Enigma -machine simulator for +machine simulator for the 27th IOCCC.

              I want to dedicate this entry in part to the millions of poor souls that were lost during the tragedy that is the Second World @@ -653,7 +653,7 @@ idea anyway. Neither do I know if the original transcoding is correct.

              (Technically above it didn’t print a newline after the output and this is how it is with some of the things I pasted in the other file and maybe others here too. Notice also how it showed the same output that my program gave it - UUMMX.)

              -

              What about the other Morse code entry?

              +

              What about the other Morse code entry?

                  $ echo IOCCC | ./prog | ./dorssel
                   ..- ..- -- -- -..-
              @@ -673,7 +673,7 @@ alternatively you can specify a file to read in.

              It has a randomise mode and it can save/read the settings to/from a file to allow for duplicity (an archaic term for the state of being double but obviously for Enigma it has to also mean deceitful).

              -

              I recommend using this in a pipeline instead of the simulator itself +

              I recommend using this in a pipeline instead of the simulator itself if you want to change the configuration of the simulator because it offers a much richer experience (and because you can reuse the configuration without having to type it out again every time).

              @@ -688,7 +688,7 @@ make it more flexible by a wrapper program.

              A parser subtlety that could cause confusion

              The parser is in a sense rather rudimentary but allows for both interactive and -automatic (e.g. via the recode program) input. This does mean that +automatic (e.g. via the recode input. This does mean that something like the following can happen:

                  $ ./prog -
                   Ring 1: 1AB
              @@ -728,14 +728,14 @@ is buffering at play I believe but it’s useful for allowing the recoderecode.html file
               (or recode.html if reading on GitHub) file I give a hint as to how
               this could be fixed but the caveat is it would necessitate a need for rewriting
              -recode.c.

              +recode.c.

              There’s another thing to be aware of and that’s the way the ranges are enforced. There are five rotors which obviously are in C 0-4 but in ‘natural language’ 1-5 (they were labelled I, II, III, IV and V though).

              There are two reflectors and the same applies: in C 0-1 but in human it’s 1-2 (technically these were reflectors B and C in -the Enigma machine which I display by name in recode.c just like +the Enigma machine which I display by name in recode.c just like with the rotors).

              For more information see recode.html (or recode.html if viewing on GitHub).

              @@ -751,7 +751,7 @@ accomplished and made use of! :)

              On the source code layout

              The layout of recode.c isn’t too significant (but see below) but I want to -mention prog.c especially:

              +mention prog.c especially:

              I did think of a more artistic layout but reflecting on it I think that the blankness of it can be another way of honouring all the @@ -784,7 +784,7 @@ has some of the ways I think this entry is obfuscated. To decipher try:

              For the lazy obfuscation.html has the deciphered version. I am afraid I’m not so inclined to do that for the cake recipe: the idea there is to make it a fun exercise that when solved unlocks a wonderful double-layered chocolate fudge -cake recipe. But given that my ‘Don’t tread on me’ award entry +cake recipe. But given that my ‘Don’t tread on me’ award entry also has the recipe (ferguson1/chocolate-cake.html if reading on GitHub), not enciphered, one might just go there instead. Still it’s a fun way @@ -825,7 +825,7 @@ processes each letter - but with the 2014 Mo can at least have the output played in Morse code as the Germans did; I think that’s really cool (I think it’s really cool even if there’s a bug in it). That it pays homage to that (and another) entry is a bonus here.

            • -
            • The simulator doesn’t report errors but tries to gracefully deal +

            • The simulator doesn’t report errors but tries to gracefully deal with them: if one chooses a value out of range it moves it into the range (if > the max then the max, if < min then the min). If invalid chars are input for the plugboard pairs then it’s not added to the plugboard etc.

            • @@ -949,7 +949,7 @@ centre, right). To do this click the button at the top right that looks like:

              -

              If I made use of the Enigma code in the recode.c program I would +

              If I made use of the Enigma code in the recode.c program I would maybe consider doing something like that but I intentionally do not use it there: as cool as it might be it would give a better idea of how the algorithm works (unless I were to make it just as obscure as I do in prog.c but that’s @@ -1003,7 +1003,7 @@ programmers. I’m especially proud to win besides Dave Burton and Yusuke Endoh but Don Yang and Edward Giles too.

              But there are some others who I don’t remember like Ilya Kurdyukov -(who’s offered a lot of interesting thoughts on Snake and +(who’s offered a lot of interesting thoughts on Snake and who plans to have his own version after the entries are published), Nathan Otterness, Nicholas Carlini (your entry is an absolutely brilliant diff --git a/2020/ferguson2/recode.html b/2020/ferguson2/recode.html index 4e8815bb9..73b962f5b 100644 --- a/2020/ferguson2/recode.html +++ b/2020/ferguson2/recode.html @@ -362,7 +362,7 @@

              The recode configurator documentation (and a fun way to explore my 2020 IOCCC Enigma simulator)

              N.B. At the end of this file I have given a fun exercise that can be used to explore my Enigma machine -simulator. I really encourage you to do this but of course you don’t +simulator. I really encourage you to do this but of course you don’t have to if you don’t wish to.

                @@ -438,8 +438,8 @@ if you don’t give the option to read in a file for input.

                Plugboard pair #09: RU Plugboard pair #10: VG 1WX5AK4RE1XEHJSAPYCIZBWDQNRUVGIOCCC
                -

                Though you won’t find some of those strings in recode.c or -prog.c. Yes the WAR for the Ringstellung (Ring settings) is an +

                Though you won’t find some of those strings in [recode.c]((https://github.com/ioccc-src/temp-test-ioccc/blob/master/2020/ferguson2/recode.c) or +[prog.c]((https://github.com/ioccc-src/temp-test-ioccc/blob/master/2020/ferguson2/prog.c). Yes the WAR for the Ringstellung (Ring settings) is an amusing coincidence but it really did happen!

                As for -f the contents would be output with the settings e.g. to pipe to prog itself (as if you redirected the file contents to the Enigma machine for @@ -565,7 +565,7 @@ pair; this can be done in a number of ways but two dots is one. Notice also that it’s in a different order than the simulator: because with the size restrictions on my entry I saved bytes by using the same loop where I could. It just felt more natural to have them -grouped together in a configurator for the simulator.

                +grouped together in a configurator for the [simulator]((https://github.com/ioccc-src/temp-test-ioccc/blob/master/2020/ferguson2/prog.c).

                    $ echo 1AA2AA3AA2ABCD..EFGHIJKLMNOPQRIOCCC | ./prog - 2>/dev/null
                     HQNVO
                     $ echo 1AA2AA3AA2ABCD..EFGHIJKLMNOPQRIOCCC  | ./prog - 2>/dev/null | echo 1AA2AA3AA2ABCD..EFGHIJKLMNOPQRHQNVO | ./prog  - 2>/dev/null
                diff --git a/2020/ferguson2/recode.md b/2020/ferguson2/recode.md
                index ba93b15b1..f8fb22658 100644
                --- a/2020/ferguson2/recode.md
                +++ b/2020/ferguson2/recode.md
                @@ -2,7 +2,7 @@
                 
                 N.B. At the end of this file I have given a fun exercise that can be used to
                 explore my [Enigma machine](https://www.cryptomuseum.com/crypto/enigma/index.htm)
                -[simulator](prog.c). I really encourage you to do this but of course you don't
                +[simulator](%%REPO_URL%%/2020/ferguson2/prog.c). I really encourage you to do this but of course you don't
                 have to if you don't wish to.
                 
                 
                @@ -97,8 +97,8 @@ if you don't give the option to read in a file for input.
                     1WX5AK4RE1XEHJSAPYCIZBWDQNRUVGIOCCC
                 ```
                 
                -Though you won't find some of those strings in [recode.c](recode.c) or
                -[prog.c](prog.c). Yes the `WAR` for the Ringstellung (Ring settings) is an
                +Though you won't find some of those strings in [recode.c]((%%REPO_URL%%/2020/ferguson2/recode.c) or
                +[prog.c]((%%REPO_URL%%/2020/ferguson2/prog.c). Yes the `WAR` for the Ringstellung (Ring settings) is an
                 amusing coincidence *but it really did happen!*
                 
                 As for `-f` the contents would be output with the settings e.g. to pipe to
                @@ -265,7 +265,7 @@ pair](https://www.cryptomuseum.com/crypto/enigma/i/sb.htm); this can be done in
                 a number of ways but two dots is one. Notice also that it's in a different order
                 than the simulator: because with the size restrictions on my entry I saved bytes
                 by using the same loop where I could. It just felt more natural to have them
                -grouped together in a configurator for the [simulator](prog.c).
                +grouped together in a configurator for the [simulator]((%%REPO_URL%%/2020/ferguson2/prog.c).
                 
                 ``` 
                     $ echo 1AA2AA3AA2ABCD..EFGHIJKLMNOPQRIOCCC | ./prog - 2>/dev/null
                diff --git a/2020/giles/README.md b/2020/giles/README.md
                index 92ec47c3c..9d33dfad8 100644
                --- a/2020/giles/README.md
                +++ b/2020/giles/README.md
                @@ -41,7 +41,7 @@ will be converted to the DTMF sound!
                     ./prog 867-5309 > jenny.wav
                 ```
                 
                -If the script [try.sh](try.sh) did not play a WAV file, it means you do not have
                +If the script [try.sh](%%REPO_URL%%/2020/giles/try.sh) did not play a WAV file, it means you do not have
                 SoX installed; see [FAQ 3.10: How do I compile and use an IOCCC entry that
                 requires sound?](../../faq.html#sox)). In this case install it and try it again or
                 play the files `jenny.wav` and `ioccc28.wav` in a program that can play WAV
                diff --git a/2020/giles/index.html b/2020/giles/index.html
                index 5df7337fd..a8e76d128 100644
                --- a/2020/giles/index.html
                +++ b/2020/giles/index.html
                @@ -398,7 +398,7 @@ will be converted to the DTMF sound!

                # See ./prog 867-5309 > jenny.wav
                -

                If the script try.sh did not play a WAV file, it means you do not have +

                If the script try.sh did not play a WAV file, it means you do not have SoX installed; see FAQ 3.10: How do I compile and use an IOCCC entry that requires sound?). In this case install it and try it again or play the files jenny.wav and ioccc28.wav in a program that can play WAV diff --git a/2020/kurdyukov1/README.md b/2020/kurdyukov1/README.md index f04930f00..a482da091 100644 --- a/2020/kurdyukov1/README.md +++ b/2020/kurdyukov1/README.md @@ -32,19 +32,19 @@ code](#alternate-code) below for more details. There are a number of alternate versions for this program, some in C and some in assembly. -The file [prog.alt.c](prog.alt.c) is smaller and does not contain any +The file [prog.alt.c](%%REPO_URL%%/2020/kurdyukov1/prog.alt.c) is smaller and does not contain any headers or any workaround for WIN32 based platforms. -The file [prog.extra.c](prog.extra.c) has a number of layouts including some for +The file [prog.extra.c](%%REPO_URL%%/2020/kurdyukov1/prog.extra.c) has a number of layouts including some for different social media profile covers as well as different shapes. -The files [prog.x86_64.asm](prog.x86_64.asm) and [prog.x86.asm](prog.x86.asm) +The files [prog.x86_64.asm](%%REPO_URL%%/2020/kurdyukov1/prog.x86_64.asm) and [prog.x86.asm](%%REPO_URL%%/2020/kurdyukov1/prog.x86.asm) are the program in assembly for x86_64 linux and x86 linux respectively. ### Alternate build: -To build [prog.alt.c](prog.alt.c): +To build [prog.alt.c](%%REPO_URL%%/2020/kurdyukov1/prog.alt.c): ``` make alt @@ -100,17 +100,17 @@ under mingw64), otherwise the hashes can be incorrect. ### Bonus -- [prog.extra.c](prog.extra.c) is the same with the sine function (so smaller), +- [prog.extra.c](%%REPO_URL%%/2020/kurdyukov1/prog.extra.c) is the same with the sine function (so smaller), and in different shapes. -- [prog.x86_64.asm](prog.x86_64.asm) contains the same program, but written in +- [prog.x86_64.asm](%%REPO_URL%%/2020/kurdyukov1/prog.x86_64.asm) contains the same program, but written in assembly for x86_64 Linux, for the sake of smaller executable size which is 500 bytes long (where 120 is for the ELF headers) after compilation. Algorithm details is slightly different (like constants packing), just to make smaller binary code. It's interesting to compare density of binary code and obfuscated C. -- [prog.x86.asm](prog.x86.asm) is for x86, although the headers are smaller, but +- [prog.x86.asm](%%REPO_URL%%/2020/kurdyukov1/prog.x86.asm) is for x86, although the headers are smaller, but the binary code is larger due to fewer registers and lack of 64-bit multiply. @@ -139,7 +139,7 @@ above: For people eager to encode large files, an extra utility has been packaged with this entry to preprocess the generated output to make them more -acceptable to typical compilers. View the [cppp.cc](cppp.cc) source and +acceptable to typical compilers. View the [cppp.cc](%%REPO_URL%%/2020/yang/cppp.cc) source and then compile it with a c++ compiler of your choice.