Prepare for the winners of **IOCCC28**. > However these are not the 2024 droids you are looking for. :-) The HTML menu (both JavaScript and non-JavaScript) has been updated. The `Status -> Rules and guidelines' have been replaced with two separate menus `Status -> IOCCC rules` and `Status -> IOCCC guidelines`. Added a new top level `social.html` page: built from a new `social.md`. Sorted rules for building specific web pages in the top level `Makefile`. Added `make social` to make the `social.html` page from `social.md`. The `bin/gen-top-html.sh` now is able to process a argument of **social** to process the new top level `social.html` page. Changed `bin/gen-top-html.sh` VERSION from "2.0.0 2025-03-13" to "2.0.1 2025-07-25". Below `About -> Home page` a new `About -> IOCCC social media` menu item as added. Because the menu change touched every HTML file, we changed the general copyright date range for HTML files from "1984-2024" to "1984-2025" due to the extensive changes made for **IOCCC28**. Those markdown files that were modified in 2025 had their copyright date range also changed from "1984-2024" to "1984-2025". Rebuilt tarballs and sitemap due to the extensive HTML rebuilding. Ran `make update` to perform the above.
To build:
make all
To use:
./cmills [starting_cash]
Try:
./cmills 5000
Judges' remarks:
The Makefile uses several -D defines. The following is is a list of the macros
that may be changed:
-DM=<max bet allowed>-DN=<52 * number of decks used>-DX=<how to seed the rand() generator>
The macro V should remain void.
The author noted that a compiler being used assumed that x=*p++ means x*=p++
but do you know why? This is not so strange as it might seem if you look at C's
history. Example code where
this occurs is in John Lions' Commentary on the Sixth Edition UNIX Operating System.
Author's remarks:
This is a blackjack program. It does splits, doubling down, insurance, etc.
As best I can figure, it should be ANSI-compliant, as well as portable to BSD &
SysV (as well as the irritating compiler I was using which assumes x=*p++
means x*=p++!). It is reasonably robust in its error handling---it won't let
you split, double, etc. unless you actually have the cash, etc. To terminate
the program, hit EOF or type 0 or a negative number for you wager.
The way it deals with splits is particularly cool (IMHO). You can split many times, and it will show all hands as they are played.