Commit Graph
100 Commits
Author SHA1 Message Date
Cody Boone Ferguson 3f19712230 Add alt code for 2000/thadgavin
This version allows for delaying between the writing of characters (for
curses) or pixels (for SDL). I explained how to reconfigure it in the
README.md file.

This is useful for more modern systems as well as if you're sensitive to
rapid swirling.

Typo fixes in README.md.
2023-07-04 09:26:32 -07:00
Cody Boone Ferguson 2d2970dc2b Remove 2000/anderson alt code
It doesn't seem like it is worth having it due to the difference being
gets() versus fgets(). One can look at the archive instead. The change,
again, is due to annoying warnings in linkers and at runtime display
issues (though redirecting stderr to /dev/null would also work well
enough if one remembers to do it).
2023-07-01 08:08:54 -07:00
Landon Curt Noll ac41f07a83 move fix thanks a file, update top level html links, rename CONTRIBUTING.md
The fix thank you's have been moved from `README.md` to
`thanks-for-fixes.md`.

**WARNING**: Some mistakes may have been made in doing this.
We presume later changes by others will correct any issues.

The `CONTRIBUTING.md` was renamed `how-to-enter.md`.

A 3rd line of links was added to top level html such as
`contact.html`, `index.html`, `judges.html`, `winners.html`,
and `years.html`.

Improved blank line use in a number (but not all) `README.md` files.
2023-06-06 16:59:53 -07:00
Cody Boone Ferguson 7dbb9fc2fe Change 'tri-graphs' to 'trigraphs' - it's one word
The is a file excluded from this commit that has had the change because
there are other changes but the file is incomplete. That file will be
committed when the fixes are complete which will happen at a later date.
2023-06-05 05:52:57 -07:00
Cody Boone Ferguson c64d9c86a2 Add -lm to 2000/briddlebane/Makefile
The entry would not compile in the systems that require the explicit use
of -lm for libm. Two example systems are fedora and Rocky linux.

I also fixed a couple typos in README.md.
2023-06-05 05:45:03 -07:00
Cody Boone Ferguson b5599f5556 Add sdl binary to 2000/thadgavin/.gitignore 2023-05-18 11:01:22 -07:00
Landon Curt Noll 5927927e51 Add .id to all winning entries 2023-05-13 11:45:33 +10:00
Landon Curt Noll c69445d067 Add .top and .year files
This will be used by tools that will build the web site
and tools that form JSON files (such as `.winner.json').
2023-05-12 20:10:38 +10:00
Cody Boone Ferguson 0e3acd6739 sgit -e 's/[[:space:]]$//g' '*Makefile'
At the request of Landon all Makefiles have had trailing spaces removed.
The request also included README.md files but this is more complicated
as some lines have to end in spaces in order to force line breaks. For
Makefiles it's fine though. Tested the Makefiles by doing 'make clobber
all everything' from the root directory and all appears to be fine. This
testing is important because depending on how this process (removal of
trailing spaces) was done it could break the Makefiles; for instance
trying something like:

    sgit -e 's/\s.*$//g' '*Makefile'

would rather break the Makefiles. This makes sense to anyone who knows
my script (and obviously sed :-) ) as long as they're not also tired but
I AM tired and so it was the first thing I tried (without thinking of
course ... though I had first thought of the correct way :-) ).

But what happens to the universes (yes I at least want to believe in the
multiverse theory and I hope it's true :-) ) when trailing spaces are
removed? :-)

As it turns out the only Makefiles touched were:

	modified:   1987/wall/Makefile
	modified:   1992/adrian/Makefile
	modified:   1994/ldb/Makefile
	modified:   2000/anderson/Makefile
	modified:   2001/anonymous/Makefile
	modified:   2001/bellard/Makefile
	modified:   2004/kopczynski/Makefile
	modified:   2015/howe/spoiler/Makefile
	modified:   2019/karns/Makefile

and most of them were my fault.
2023-05-11 02:28:26 -07:00
Cody Boone Ferguson 847ccdc232 Update David Lowe URL
I know that in bugs.md there is a missing URL for him or at least about
one of the entries but I'll have to look at that later. It might be that
it should stay there as it was a website for the entry itself and it
would be nice to have it back but for now this is unaddressed.
2023-05-10 09:49:30 -07:00
Cody Boone Ferguson 43287b6a4a Update 2000/jarijyrki/.gitignore 2023-05-01 09:56:28 -07:00
Cody Boone Ferguson 66231b2150 Remove 'America' (A) from 'USA' :-)
This to make the country code consistent with mkiocccentry (and I guess
international standard country codes).

This affects many README.md files and (for one line) winners.csv.
2023-04-22 04:21:38 -07:00
Cody Boone Ferguson bee1d82370 Fixes and updates to 2000/tomx
Format fixes in README.md.

Link fix via the Internet Wayback Machine. This was also fixed in
winners.csv and winners.html.

Copy ../mkentry.c to this directory because the author made an example
of where one can modify the program to compile it instead - it felt
better than to change it to ../mkentry.c as that assumes the directory
structure is the same.

Added mkentry to .gitignore.
2023-04-20 13:18:29 -07:00
Cody Boone Ferguson 93e97ec356 Add reference to dd0b2 in 2000/thadgavin/README.md
This is because it's so bizarre, amusing and bemusing that some might
like to see it (of course many won't :-) ).
2023-04-20 13:07:26 -07:00
Cody Boone Ferguson dd0b26b5d6 Fix 2000/thadgavin for SDL + format README.md
The SDL version did not work for a number of reasons. First of all the
code requires that SDL is defined. Second the path wrong header file was
included. Third the SDL1 developers thought it would be a great idea
(but obviously it's a terrible idea) to redefine main() (!!) so that any
program that uses SDL1 has to have the same args as their definition.
This program had 'main()' so the error message was:

    thadgavin.c:60:1: error: conflicting types for 'SDL_main'
    main()
    ^
    /opt/local/include/SDL/SDL_main.h:34:14: note: expanded from macro 'main'
    #define main SDL_main
		 ^
    /opt/local/include/SDL/SDL_main.h:35:12: note: previous declaration is here
    extern int SDL_main(int argc, char *argv[]);
	       ^
    1 warning and 1 error generated.
    make: *** [thadgavin_sdl] Error 1

Thus main() was changed to 'int main(int argc, char **argv)'. I am not
sure if I want to know their thinking. I kind of do but I also don't.

Format fix README.md.
2023-04-20 12:59:06 -07:00
Cody Boone Ferguson 43d4057682 Format fix 2000/schneiderwent/README.md 2023-04-20 12:35:23 -07:00
Cody Boone Ferguson e6dfaf0d52 Format fix 2000/robison/README.md 2023-04-20 10:22:21 -07:00
Cody Boone Ferguson 4d19b7a11c Fix 2000/rince/README.md + update bugs.md
There is a known crash in the program if DISPLAY is unset.

Typo fixed and format fixed.
2023-04-20 09:24:39 -07:00
Cody Boone Ferguson 132518a399 Typo check 2000/primenum/README.md
Added INABIAF section as well. This has been added to bugs.md as well
(some were already there but one was not - the known crash that's a
feature).
2023-04-20 08:50:52 -07:00
Cody Boone Ferguson 62aea3c81c Format fixes in 2000/jarijyrki/README.md
I've now looked at the entire README.md file and fixed formatting.

I also renamed the sheet1.info file to finance.sheet as it seems a more
appropriate name for usability.
2023-04-20 08:38:26 -07:00
Cody Boone Ferguson feedb3cf50 Author format fix in 2000/schneiderwent
This will be the 97th open pull request by me so I have to say the
following insightful (or it will be to Landon .. and me) number:
2305567963945518424753102147331756070 since it's so magical.
2023-04-19 14:34:08 -07:00
Cody Boone Ferguson dcad5e6c78 Format fix author info in 2000/robison 2023-04-19 14:33:09 -07:00
Cody Boone Ferguson d573b1df82 Fix (some?) links in 2000/rince/README.md
Fix some of the formatting as well.

More has to be done with this file.
2023-04-19 14:31:51 -07:00
Cody Boone Ferguson 5f48d50fb6 Format fix 2000/primenum/README.md
I didn't check for typos. That will come later.
2023-04-19 14:24:15 -07:00
Cody Boone Ferguson ce9bfca9c7 Fix 2000/natori and add alt code
The author suggested alternate code for those in the southern hemisphere
which the natori.alt.c now has.
2023-04-19 13:55:41 -07:00
Cody Boone Ferguson a71e0f4c99 Partially fix 2000/jarijyrki
The URL for one of the authors was no longer valid so I had to use the
Internet Wayback Machine. The winners.html and winners.csv files have
been updated for this change.

Format the authors' information.

That's all there is this time as I have to think on how to do the
formatting in a way that matches their set up (sections and numbers).
This will have to come another time.
2023-04-19 13:49:52 -07:00
Cody Boone Ferguson 64f0c5c84f Format and typo fix 2000/dlowe/README.md 2023-04-19 13:18:54 -07:00
Cody Boone Ferguson 73d0c06440 Format and typo fix 2000/dhyang/README.md 2023-04-19 13:00:58 -07:00
Cody Boone Ferguson 77cb6b6030 Format fix + add try in 2000/briddlebane
Suggest that one runs this from .bashrc or equivalent files for some
good fun on log in. :-)
2023-04-19 12:48:51 -07:00
Cody Boone Ferguson acdb26d5c4 Format and link fix 2000/bmeyer, update .gitignore 2023-04-19 12:43:05 -07:00
Cody Boone Ferguson ea79092508 Fix 2000/bellard/README.md
In a previous commit I had accidentally changed 'Author's remarks' to
'Alternate code' (I have no idea how this happened).

Another typo was fixed.

Added a note how this no longer (of course) prints the largest prime
known.

Fix URL.

Fix formatting.
2023-04-19 12:08:29 -07:00
Cody Boone Ferguson 305c8ce3e9 Format fixes in 2000/anderson/README.md
I observed something strange though: the author noted the output of the
input 'Hello, world!' and it doesn't appear to match the program before
or after the fgets() change. I'm not sure if this is a bug or if it is
(as I guess) a formatting problem.
2023-04-19 12:00:17 -07:00
Cody Boone Ferguson bb5fb53949 Remove 2000/anderson alt code - has no purpose 2023-04-17 10:21:53 -07:00
Cody Boone Ferguson 9e323d8392 Remove colon at end of award in README.md files
As in

    sgit -e '1s/:$//g' '*README.md'
2023-04-11 08:43:41 -07:00
Cody Boone Ferguson 4bf3f302cb 'comments' -> 'remarks' in all README.md files
As in

    sgit -e 's/\([Aa]uthor.*\)comments/\1remarks/g' -e 's/\([Jj]udge.*\)comments/\1remarks/g' '*README.md'
2023-04-10 11:01:39 -07:00
Cody Boone Ferguson 392e82dc85 Fixes to 2000/primenum
The entry does not do what one might expect so add a note about this.

Fixed commands to try.

Format fixes.

Make main() void again as part of redefinition of INABIAF.
2023-04-07 11:25:03 -07:00
Cody Boone Ferguson 3e29d777ce Reword note about fix in 2000/natori
I had said the fix I did made it works with modern compilers but fixed
for modern compilers is more precise though it might be a subtle
difference.
2023-04-07 11:20:36 -07:00
Cody Boone Ferguson 727f1e1fe1 Reword note about fgets() in 2000/anderson 2023-04-07 11:19:36 -07:00
Cody Boone Ferguson 06a5665f5d Make alt code for gets() / fgets() changes
As both Landon and I have been wondering if changing entries to use
fgets() is bordering on tampering with entries I decided to make the
original (sometimes bug fixed) versions (using gets()) alt code. I had
originally started to make the fgets() version of each entry the alt but
since the fgets() versions can handle input better and since some also
fixed bugs (see below) I decided to make the original version the alt
code (this also is how it is for other entries).

There were some exceptions here. If the change also fixed some crashes
or other bugs outside of the gets() to fgets() conversion I did not
bother to make an alt version. An example is 1992/dds. In some cases the
alt code does have bug fixes in which case they were added.

Updated the Makefiles and .gitignore files as well for the alt target
and the new files (compiled and in the case of 1992/adrian additional
source files in the Makefile alt rule).

This should solve the problem observed by Landon and me. It wouldn't be
a problem to change it so the alt version is the one that uses fgets()
but I think that might be the wrong choice.

In some entries I altogether avoided changing to fgets() say if the
author notes it uses gets() (in one case even providing a version that
uses fgets()). In some cases using fgets() introduces a bug so those are
also not changed.

As for 1990/tbr there's a strong reason for not having the fgets()
version being the alt. In macOS in particular (in linux - or maybe gcc,
not sure - it shows a warning at linker time) it will mess up the first
line of output in a potentially confusing way. For instance:

    $ ./tbr.alt
    $ warning: this program uses gets(), which is unsafe.
    # nothing here, what to do?

And that touches on another issue of making the alt version the one that
uses gets(): the warnings that can be alarming during compilation,
linking and (in the case of macOS) runtime.

Not all entries should be or can be changed to fgets() but some can and
it's warranted for these reasons. More will possibly happen in the
future.
2023-04-05 05:22:35 -07:00
Cody Boone Ferguson e09f677b37 Mass typo fix (all README.md and Makefiles)
As in

    sgit -e 's/the terms this license/the terms of this license/g' '*/Makefile' '*/README.md'
2023-04-02 09:27:13 -07:00
Cody Boone Ferguson e805f41d34 Mass fixes to headers in README.md files
There were many many README.md files with the wrong heading level for
different sections. These have been changed.

To help go through the changes it should be noted I used sgit and also
here is what is changed:

The 'Try', 'To build' and 'To run' lines have two '#'s. Some had one and
others had three.

An exception is that in 1984/anonymous/README.md for the alternative
code that had three '#'s. This is not consistent yet and it might be
that only two are desired. But for now that one at least has three.
2023-03-31 06:43:59 -07:00
Landon Curt Noll 350da723cc improve architecture and Optimization comments in Makefiles 2023-03-26 22:13:13 -07:00
Landon Curt Noll 1c35dc3b47 make everything true :-)
Add @${TRUE} as an action for the everything rule in Makefiles.
2023-03-26 20:47:04 -07:00
Landon Curt Noll e42d7484cd trim comments and update 133t hacker rulz in Makefiles 2023-03-26 20:24:16 -07:00
Landon Curt Noll 1b1dd2f2e4 put all README.md files under CC BY-SA 4.0 License
This will make is easier for others to share README.md
files while requiring them to attribute the file
when using it.
2023-03-26 02:58:27 -07:00
Landon Curt Noll ea1806abdb change Makefiles to look under X11_INCDIR and X11_INCDIR/X11 2023-03-26 02:22:49 -07:00
Landon Curt Noll 8cd2aa85c1 clean up and improve end of Makefile rules 2023-03-26 02:02:31 -07:00
Landon Curt Noll d04e6d8f03 remove X11_LIBDIR and X11_INCDIR setting from Makefiles
The X11_LIBDIR and X11_INCDIR values are now set in the
top level `var.mk` file.
2023-03-26 00:50:47 -07:00
Landon Curt Noll bbd18a20df improve Makefile headers
Simply the Makefile header.

Refer to the //www.ioccc.org/bugs.md URL (that will eventually exist).

Now using CC BY-SA 4.0 License to how you may share and adapt the
Makefile.
2023-03-25 23:51:14 -07:00
Cody Boone Ferguson a68a5d4d18 Many README.md files updated
Formatting and other notes. Many more need to be checked for this but I
wanted these changes out of the way of git status to try and clean my
working changes.
2023-03-24 04:40:30 -07:00