Update 1988/litmaath
Format and typo check the README.md file. Improved the order of the alt code (displayed by the judges) and what followed it (that might seem like it's related to the alt code when although maybe true it still is about the entry itself). Updated thanks file to refer to the alt code and removed myself from the README.md (this before the far superior idea of a single file outside of the entries existed and because some entries were missed, this one included).
This commit is contained in:
1 parent
5832e2b656
commit
5b4847ce70
2 files changed
+23
-10
No files matched your search
+19
-10
@@ -1,6 +1,6 @@
|
||||
# Best small program
|
||||
|
||||
Maarten Litmaath
|
||||
Maarten Litmaath<br>
|
||||
The Netherlands
|
||||
|
||||
## To build:
|
||||
@@ -15,7 +15,8 @@ make
|
||||
./litmaath some text
|
||||
```
|
||||
|
||||
There is an alternate version provided. See the Alternate code section below.
|
||||
There is an alternate version provided. See the [Alternate
|
||||
code](#alternate-code) section below.
|
||||
|
||||
## Try:
|
||||
|
||||
@@ -25,9 +26,13 @@ There is an alternate version provided. See the Alternate code section below.
|
||||
|
||||
### Alternate code:
|
||||
|
||||
[Cody Boone Ferguson](/winners.html#Cody_Boone_Ferguson) added the
|
||||
[litmaath.alt.c](litmaath.alt.c) which we described in our remarks below. To
|
||||
use:
|
||||
|
||||
This alternate code, added to help understand the entry and for fun, is code
|
||||
that we suggested at the time of the entry publication but which we never put in
|
||||
a file.
|
||||
|
||||
#### To build:
|
||||
|
||||
|
||||
```sh
|
||||
make alt
|
||||
@@ -35,7 +40,11 @@ make alt
|
||||
|
||||
Use `litmaath.alt` as you would `litmaath` above.
|
||||
|
||||
Thank you Cody!
|
||||
#### Try:
|
||||
|
||||
```sh
|
||||
./litmaath.alt six was afraid of seven because seven eight nine
|
||||
```
|
||||
|
||||
|
||||
## Judges' remarks:
|
||||
@@ -50,10 +59,12 @@ while (<condition>)
|
||||
|
||||
Did you notice that the body is empty?
|
||||
|
||||
Furthermore, it's interesting to note that only two variables are
|
||||
used to achieve everything.
|
||||
|
||||
The best one can do to understand how the program works is to give it
|
||||
two small strings as arguments, and follow the program closely. One
|
||||
could make the body of the 'while' loop an 'fprintf' with interesting
|
||||
could make the body of the `while` loop an `fprintf` with interesting
|
||||
variables like:
|
||||
|
||||
|
||||
@@ -64,15 +75,13 @@ fprintf(stderr,
|
||||
(long) argv[1], argv[1] && *argv[1] ? *argv[1] : '@', argc);
|
||||
```
|
||||
|
||||
... which is what the [alternate code](#alternate-code) is.
|
||||
|
||||
Furthermore, it's interesting to note that only two variables are
|
||||
used to achieve everything.
|
||||
|
||||
## Author's remarks:
|
||||
|
||||
No remarks were provided by the author.
|
||||
|
||||
|
||||
## Copyright and CC BY-SA 4.0 License:
|
||||
|
||||
This file is Copyright (c) 2023 by Landon Curt Noll. All Rights Reserved.
|
||||
|
||||
@@ -408,6 +408,10 @@ function, a redefinition of `exit()`, was not being called in main(). The
|
||||
original version is in [1988/isaak/isaak.alt.c](1988/isaak/isaak.alt.c). See the
|
||||
README.md file for more details.
|
||||
|
||||
## [1988/litmaath](1988/litmaath/litmaath.c) ([README.md](1988/litmaath/README.md))
|
||||
|
||||
Cody added the alt code which is code that we suggested at the time of
|
||||
publication, in the remarks, to help understand the entry, and for fun.
|
||||
|
||||
## [1988/phillipps](1988/phillipps/phillipps.c) ([README.md](1988/phillipps/README.md]))
|
||||
|
||||
|
||||
Reference in new issue
Block a user