Files
ioccc/1990/cmills
Cody Boone Ferguson af5482825c Reorganise menus
The sections have been modified a fair amount. The Entries menu has been
extended to have: Fixing entries, Updating author info, Thanks for the
help. The first two were moved from FAQ and the last one from About.
The rationale for these, in order: entries and authors have to do with
entries and most of the help involves entries. It also has to do with
website but in 'about' it does not seem the right place, unless maybe it
is renamed to 'Credits' or something (I am not suggesting this one way
or the other). This one is debatable but that was the rationale.

The Status menu has been extended to have: Markdown guidelines and
Security policy. The rationale is that the markdown guidelines are part
of contest guidelines and the security policy is about the status of the
entries and how if there are any security problems they will not be
addressed (instead of about the IOCCC).

The FAQ was extended to have: Compiling entries, Running entries, How to
help. The reason to not have compiling and running entries under Entries
is because this is 'how to' and also the menu was too long. How to help
seems like a good idea under FAQ too (was in About).

About was extended to have the new 'about.html' page (from about.md).
This is a rare case where a new file is useful as it fits under 'About'.
The menu now is: Home page, About the IOCCC, The Judges, Contact us. I
was pondering the 'About [the IOCCC]' at the top and also naming it
'About us' but it seemed like a link to index.html was necessary and as
for 'about us' it seemed less clear as to whether it was about the
judges or the contest itself. The FAQ has been updated slightly for
this.

After further inspection the bin/index.html and the inc/index.html links
were removed from the about section.

With these changes, renaming an item or slight reordering
notwithstanding, I believe that #2006 is probably in good shape.
2024-10-25 11:23:21 -07:00
..
2023-09-11 05:58:09 -07:00
2023-07-06 21:49:38 -07:00
2024-10-25 11:23:21 -07:00

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.