Format/typo fixes in 1994/shapiro

This completes 1994/shapiro as long as a formatting change in shapiro.md
is correct. That will be checked and if necessary it will be fixed.
This commit is contained in:
Cody Boone Ferguson committed 2023-11-10 09:38:35 -08:00
1 parent eb5845072e
commit e25615b987
2 files changed
+48 -48

No files matched your search

+17 -17
View File
@@ -30,12 +30,14 @@ For more detailed information see [1994 shapiro in bugs.md](/bugs.md#1994-shapir
^Z
bg
ps x
fg
^C
./shapiro_t1
```
Notice what you see in the output of `ps`!
Notice what you see in the output of `ps`! Observe too that after you bring it
back to the foreground what happens.
## Judges' remarks:
@@ -60,29 +62,27 @@ The basic theme (pun) of this program is:
> ~~~~
My entry ([shapiro.c](shapiro.c)) is mostly comment, formatted in the shape of a\
clock. If you strip out the comments and look at the code you will\
quickly realize that the comments were the important part and that\
the code does very little (see pun above). It writes (to stdout)\
another C program ([shapiro_t2.c](shapiro_t2.c)). This is the first level of\
My entry ([shapiro.c](shapiro.c)) is mostly comments, formatted in the shape of a
clock. If you strip out the comments and look at the code you will
quickly realize that the comments were the important part and that
the code does very little (see pun above). It writes (to `stdout`)
another C program ([shapiro_t2.c](shapiro_t2.c)). This is the first level of
obfuscation.
The second program ([shapiro_t2.c](shapiro_t2.c) if you use the Makefile
The second program ([shapiro_t2.c](shapiro_t2.c) (use `make everything` first)
prints a clock in the upper right hand corner of your VTxxx/ANSI display.
Most of the surface obfuscation in the second program
([shapiro_t2.c](shapiro_t2.c))\
was an attempt to make it as small as possible. You should be able to\
see around this with cb(1) and some more intelligent variable names.\
Once you get past this you will realize that the third level of\
obfuscation is a six member client/server hierarchy.\
(See the [shapiro.md](shapiro.md) file for a detailed description of the
algorithm.)
([shapiro_t2.c](shapiro_t2.c)) was an attempt to make it as small as possible.
You should be able to see around this with `cb(1)` and some more intelligent
variable names. Once you get past this you will realize that the third level of
obfuscation is a six member client/server hierarchy. (See the
[shapiro.md](shapiro.md) file for a detailed description of the algorithm.)
`lint` complains about: precedence confusion, `K` may be used before set,
main() returns random value to invocation environment, value type used\
inconsistently, value type declared inconsistently, function argument\
(number) used inconsistently, function returns value which is always\
`main()` returns random value to invocation environment, value type used
inconsistently, value type declared inconsistently, function argument
(number) used inconsistently, function returns value which is always
ignored, function returns value which is sometimes ignored.
All of which are harmless (famous last words).