diff --git a/2000/schneiderwent/Makefile b/2000/schneiderwent/Makefile index 7740dc135..7b81e502d 100644 --- a/2000/schneiderwent/Makefile +++ b/2000/schneiderwent/Makefile @@ -75,8 +75,8 @@ CWARN= -Wall -Wextra -pedantic ${CSILENCE} # Compiler standard # #CSTD= -CSTD= -ansi -#CSTD= -std=gnu99 +#CSTD= -ansi +CSTD= -std=gnu99 # Compiler bit architecture # @@ -101,7 +101,7 @@ CINCLUDE= #CINCLUDE= -include stdlib.h #CINCLUDE= -include stdio.h #CINCLUDE= -include stdlib.h -include stdio.h -#CINCLUDE= -I ${X11_INCDIR} +#CINCLUDE= -I ${X11_INCDIR} -I ${X11_INCDIR}/X11 #CINCLUDE= `${SDL2_CONFIG} --cflags` # Optimization @@ -138,8 +138,7 @@ CC= cc # ifeq ($(CC),clang) # -CSILENCE+= -Wno-missing-variable-declarations -Wno-poison-system-directories \ - -Wno-shorten-64-to-32 -Wno-sign-conversion +CSILENCE+= -Wno-missing-variable-declarations -Wno-poison-system-directories # CWARN+= -Weverything # @@ -324,4 +323,3 @@ pluto: charon @echo "dwarf is a type of planet" @echo "therefore, $@ is a planet" @echo "having lots of planets is good feature because supernovae can help ${MAKE} a lot of them" - diff --git a/2000/schneiderwent/README.md b/2000/schneiderwent/README.md index 30e65c8b2..3fa62c419 100644 --- a/2000/schneiderwent/README.md +++ b/2000/schneiderwent/README.md @@ -1,63 +1,73 @@ -Most Timely Output: +# Most Timely Output: - Craig Schneiderwent - WI, USA +Craig Schneiderwent +WI, USA -## To build: +# To build: - make all +```sh +make +``` -### To run +### To run: - ./schneiderwent schneiderwent.data +```sh +./schneiderwent datafile +``` -## Judges' comments +### Try: - Very nice play by the rules and portable text obfuscation. - This far surpasses old tricks like adding or subtracting 1 - from every character in a C string. +```sh +./schneiderwent schneiderwent.data +``` - Translating the messages into your language of preference while - keeping the program portable between different encodings - (Chinese, Japanese, Russian - anyone?) may be an entertaining task. +## Judges' comments: -## Author's comments +Very nice play by the rules and portable text obfuscation. +This far surpasses old tricks like adding or subtracting 1 +from every character in a C string. - This entry displays the current time to the console, for example: +Translating the messages into your language of preference while +keeping the program portable between different encodings +(Chinese, Japanese, Russian - anyone?) may be an entertaining task. - it's just after ten 'til 6 in the evening +## Author's comments: - FWIW, none of the compilers with which this entry was tested issued - any warnings or errors in compiling the source for this entry. No - doubt lint will complain about the goto statements. +This entry displays the current time to the console, for example: - The schneiderwent.data file consists of the values used by multiple - table lookups. This is simply good program design, separating - these values from the source code allows changing the behavior of - the application without recompiling. + it's just after ten 'til 6 in the evening - Having learned COBOL at an early age, the pthreads of my thought - processes tend to be translated into code in a verbose manner. Some - of the #defines in this entry's code are to mitigate this personal - deficiency. +FWIW, none of the compilers with which this entry was tested issued +any warnings or errors in compiling the source for this entry. No +doubt lint will complain about the goto statements. - Obfuscation in this entry consists of: +The schneiderwent.data file consists of the values used by multiple +table lookups. This is simply good program design, separating +these values from the source code allows changing the behavior of +the application without recompiling. - > printfing console messages stored as EBCDIC character values - this - is not an attempt at encryption, but rather at cross platform - compatibility - > ASCII character values are calculated from the EBCDIC in a - particularly ugly abuse of the '?' operator - > detection of whether to print the ASCII or EBCDIC values is done by - taking the remainder of dividing the character 'J' by 2 - the ASCII - value of the character is even, the EBCDIC value is odd - > the messages to be printfed are determined via multiple table - lookups and bitmasked values - > for minutes, the bit position turned on is multiplied by two - to determine the message to be printfed - > for hours, the straight bit position is used - > this entry mostly eschews function calls for the often overlooked - setjmp/longjmp combination - > the trigraphs are not there as obfuscation nor are they there to - annoy the judges - it's just the easiest way to get around the - absence of square brackets in a normal 3270 environment +Having learned COBOL at an early age, the pthreads of my thought +processes tend to be translated into code in a verbose manner. Some +of the #defines in this entry's code are to mitigate this personal +deficiency. + +Obfuscation in this entry consists of: + + > printfing console messages stored as EBCDIC character values - this + is not an attempt at encryption, but rather at cross platform + compatibility + > ASCII character values are calculated from the EBCDIC in a + particularly ugly abuse of the '?' operator + > detection of whether to print the ASCII or EBCDIC values is done by + taking the remainder of dividing the character 'J' by 2 - the ASCII + value of the character is even, the EBCDIC value is odd + > the messages to be printfed are determined via multiple table + lookups and bitmasked values + > for minutes, the bit position turned on is multiplied by two + to determine the message to be printfed + > for hours, the straight bit position is used + > this entry mostly eschews function calls for the often overlooked + setjmp/longjmp combination + > the trigraphs are not there as obfuscation nor are they there to + annoy the judges - it's just the easiest way to get around the + absence of square brackets in a normal 3270 environment