Format/typo check 1993/ejb

This includes updates to the patience.md file. The hanoi.md did not
require any changes.
This commit is contained in:
Cody Boone Ferguson committed 2023-11-09 11:00:08 -08:00
1 parent db9d6cb222
commit 0bbff5901f
2 files changed
+30 -28

No files matched your search

+8 -8
View File
@@ -54,8 +54,8 @@ text description of how to solve the puzzle.
For the patience puzzle, the output is a sequence binary codes representing
successive states of the puzzle. The rightmost digit represents the first ring.
A "1" means the ring is on the U; a "0" means it is off the U. The program
prints the word "Invalid" in response to illegal command line parameters.
A `1` means the ring is on the `U`; a `0` means it is off the `U`. The program
prints the word `"Invalid"` in response to illegal command line parameters.
### Motivation
@@ -67,14 +67,14 @@ This program serves to show that counting semicolons will not
always provide a meaningful measure of code size. This is
especially true in this program where the number of semicolons
itself is ambiguous. Does it have two or three? In addition, the
only "C" keyword this program uses besides type names and
only C keyword this program uses besides type names and
qualifiers is `return`, and the only function defined in the code
is `main`. The level of complexity of the program without multiple
is `main()`. The level of complexity of the program without multiple
semicolons, statements, and functions is achieved by abusing C
operators, especially the comma operator. Considerable use of `||`,
`&&`, and `? :` helps too. In addition, main is called recursively.
The NULL pointer that terminates argv is used to pass additional
information into main. Even though the algorithms used by this
`&&`, and `?:` helps too. In addition, `main()` is called recursively.
The NULL pointer that terminates `argv` is used to pass additional
information into `main()`. Even though the algorithms used by this
code are simple, this program is still hard to follow even when
indented properly. (It is pretty hard to indent this code
reasonably, however.)
@@ -85,7 +85,7 @@ preprocessor at all. The only functions it uses are `atoi()`, `malloc()`,
`memset()`, `printf()`, and `puts()`. It does, however, require that the
architecture it runs on have bytes that are at least eight bits long and
pointers that are at least four bytes long. In addition, it requires an ANSI
compiler since it uses "signed char" and ANSI-style function declarations.
compiler since it uses `signed char` and ANSI-style function declarations.
## Copyright and CC BY-SA 4.0 License: