1990 International Obfuscated C Code Contest winners 1 of 2

Landon C. Noll chongo at hoptoad.uucp
Sat Mar 9 00:13:01 AEST 1991


I was unable to find the 1990 IOCCC winners on uunet, so here is a reposting
of them.  Sorry for the repeat, but there is normally a collection of people
who want to see last year when the rules are posted.

Submitted-by: chongo at toad.com (Landon Curt Noll)
#
# Send comments, questions, bugs to: 
#
#    judges at toad.com   -or-   ...!{sun,uunet,utzoo,pyramid}!hoptoad!judges
#
# You are strongly encouraged to read the new contest rules before
# sending any entries.  The rules, and sometimes the contest Email
# address itself, change over time.  A valid entry one year may
# be rejected in a later year due to changes in the rules.  The typical
# start date for a contest is early March.  The typical end date for a
# contest is late May.
#
# The contest rules are posted to comp.unix.wizards, comp.lang.c,
# misc.misc, alt.sources and comp.sources.d.  If you do not have access 
# to these groups, or if you missed the early March posting, you may 
# request a copy from the judges, via Email, at the address above.
#
Archive-name: ioccc.1990/part01

---- Cut Here and unpack ----
#!/bin/sh
# This is ioccc.1990, a shell archive (shar 3.32)
# made 09/23/1990 00:16 UTC by chongo at toad.com (Landon Curt Noll)
#
# Send comments, questions, bugs to: 
#
#    judges at toad.com   -or-   ...!{sun,uunet,utzoo,pyramid}!hoptoad!judges
#
# You are strongly encouraged to read the new contest rules before
# sending any entries.  The rules, and sometimes the contest Email
# address itself, change over time.  A valid entry one year may
# be rejected in a later year due to changes in the rules.  The typical
# start date for a contest is early March.  The typical end date for a
# contest is late May.
#
# The contest rules are posted to comp.unix.wizards, comp.lang.c,
# misc.misc, alt.sources and comp.sources.d.  If you do not have access 
# to these groups, or if you missed the early March posting, you may 
# request a copy from the judges, via Email, at the address above.
#
# Source directory /usr4/chongo/bench/contest
#
# existing files WILL be overwritten
#
# This shar contains:
# length  mode       name
# ------ ---------- ------------------------------------------
#   1265 -r--r--r-- 1990/README
#   8876 -r--r--r-- 1990/rules
#   1622 -r--r--r-- 1990/Makefile
#   1711 -r--r--r-- 1990/ansi.mk
#   2327 -r--r--r-- 1990/common.mk
#    231 -r--r--r-- 1990/baruch.c
#   1512 -r--r--r-- 1990/cmills.c
#   1536 -r--r--r-- 1990/dds.c
#   1526 -r--r--r-- 1990/dg.c
#    999 -r--r--r-- 1990/jaw.c
#    879 -r--r--r-- 1990/pjr.c
#   1474 -r--r--r-- 1990/scjones.c
#      2 -r--r--r-- 1990/stig.c
#    886 -r--r--r-- 1990/tbr.c
#   1511 -r--r--r-- 1990/theorem.c
#   1529 -r--r--r-- 1990/westley.c
#   1908 -r--r--r-- 1990/baruch.hint
#   1054 -r--r--r-- 1990/cmills.hint
#   2315 -r--r--r-- 1990/dds.hint
#   1733 -r--r--r-- 1990/dg.hint
#   7401 -r--r--r-- 1990/jaw.hint
#   1479 -r--r--r-- 1990/pjr.hint
#   2466 -r--r--r-- 1990/scjones.hint
#   2213 -r--r--r-- 1990/stig.hint
#   3890 -r--r--r-- 1990/tbr.hint
#   2585 -r--r--r-- 1990/theorem.hint
#   1489 -r--r--r-- 1990/westley.hint
#   1624 -r--r--r-- 1990/LANDER.BAS
#    136 -r--r--r-- 1990/stig.ksh
#   1522 -r--r--r-- 1990/shark.sh
#
if touch 2>&1 | fgrep 'amc' > /dev/null
 then TOUCH=touch
 else TOUCH=true
fi
# ============= 1990/README ==============
if test ! -d '1990'; then
    echo "x - creating directory 1990"
    mkdir '1990'
fi
echo "x - extracting 1990/README (Text)"
sed 's/^X//' << 'SHAR_EOF' > 1990/README &&
X1990 marked the "The Seventh International Obfuscated C Code Contest"
X
XInstructions for use: Run make to compile entries (it is possible that
Xon System V or non-unix systems the makefile needs to be changed). The
Xansi.mk may need to be changed if your ANSI C compiler is not gcc.
X
XLook at the source and try to figure out what the programs do, and run
Xthem with various inputs.  If you want to, look at the hints files for
X(minor) spoilers.
X
XThis year, the Grand Prize won a standing ovation at USENIX.
X
XThe "Strangest abuse of the rules" award was given this year to stress
Xthe fact that starting in 1991, entries should be shell-specific.
X
XThis year was the first year that we accepted ANSI C entries.  It was
Xinteresting to note that the ANSI C entries were as a whole less
Xportable than the K&R C entries.  We hope that in future contests
Xpeople will enter more obfuscated and challenging ANSI C programs.
X
XWe would like to thank Barbara Frezza (loving wife of Larry Bassel) for
Xher role as official chef of the contest.  Her opinions regarding
Xsome of the contest entries were appreciated.
X
XRules and results were posted to comp.lang.c, comp.sources.unix, and
Xalt.sources.  They have been made available on a wide number of Usenet
Xarchive sites such as uunet.
SHAR_EOF
$TOUCH -am 0922163990 1990/README &&
chmod 0444 1990/README ||
echo "restore of 1990/README failed"
set `wc -c 1990/README`;Wc_c=$1
if test "$Wc_c" != "1265"; then
	echo original size 1265, current size $Wc_c
fi
# ============= 1990/rules ==============
echo "x - extracting 1990/rules (Text)"
sed 's/^X//' << 'SHAR_EOF' > 1990/rules &&
X7th International Obfuscated C Code Contest Rules
X
X	Obfuscate:  tr.v.  -cated, -cating, -cates.  1. a.  To render obscure.
X		b.  To darken.  2. To confuse:  his emotions obfuscated his
X		judgment.  [LLat. obfuscare, to darken : ob(intensive) +
X		Lat. fuscare, to darken < fuscus, dark.] -obfuscation n.
X		obfuscatory adj.
X
XGOALS OF THE CONTEST:
X
X    * To write the most Obscure/Obfuscated C program under the rules below.
X    * To show what should NOT be done in C programs.
X    * To provide a safe forum for poor C code.  :-)
X
XDEDICATION:
X
X    The 1990 International Obfuscated C Code Contest is dedicated to ANSI C.
X
XRULES:
X
X    To help us handle the vast volume of entries, we ask that you
X    follow the rules below.  Sorry for the length, but we need all
X    the help we can get!
X
X    1) Your source MUST be 1536 bytes or less, and it must be a complete
X       program, not just a subroutine.
X
X    2) To help us process your entries, we ask that you submit entries
X       in the following format.  Please be sure to include ALL --- lines,
X       otherwise our extraction program may skip your entry!
X
X---header items---
Xname:    	Your name, of course!
Xorg:		School/Company/Organization
Xemail address:	Email address from a well known site, or in a registered domain
Xpostal address:	Postal address
X		include your country as well
Xenvironment:	Indicate the Hardware 
X		and OS under which your program was tested
Xentry:		5	<number of entries sent so far including this one>
Xremarks:	Remarks may be continued with leading whitespace until the
X		line ---how to compile-- is encountered.  (see #3 below)
X---how to ANSI compile---
XX Give the command(s) needed to compile your program using an ANSI C
XX compiler.  If you program should not be compiled under an ANSI C compiler, 
XX leave this section blank.  Follow the format rules for the program 
XX section below, except that command size must be 160 characters or less.
X---how to common compile---
XX Give the command(s) needed to compile your program using an K&R/traditional
XX C compiler.  If you program should not be compiled under a K&R style C, 
XX leave this section blank.  Follow the format rules for the program section
XX below, except that command size must be 160 characters or less.
X---program---
XX Place obfuscated source of 1536 characters or less in this section.
XX Add a leading X to each line to avoid problems with mailers.
XX Some mailers don't like files with very long lines.  If your entry contains E
XC    lines longer 80 chars we ask you to form continuation line sets.  To form E
XC    a continuation line set, place an 'E' character at the point of a split E
XC    and place a C (instead of an X) at the beginning of the next line. E
XC    Finally, end the continuation line set as normal.
XX The E\nC's and leading X's will be removed prior to extraction and thus E
XC    they don't contribute toward the source character count.  All other E
XC    characters are considered to be source.  Whitespace after 'X' or 'C' E
XC    and before the 'E' is significant, we added it here for readability.
XX Newlines and tabs each count as 1 character.  Assume 8 character tab stops.
XX If your entry does not end in a newline, leave a final 'E' on the end. E
X---end---
X
X    3) Regarding the header items:
X
X	* Any text outside of the above format will be kept confidential.
X
X	* All header lines are required, but you may use 'anonymous'
X	  for any header line other than 'remarks' or 'entry'.
X
X	* In the 'remarks' please include:
X	    - what this program does
X	    - why you think the program is obfuscated
X	    - any other remarks (humorous or otherwise)
X	
X    4) Your entry should be written in common C (K&R + common extensions)
X       or ANSI C.  If your program will NOT compile under an ANSI C or 
X       K&R C compiler, leave the particular 'how to' section blank.
X
X       You do not have to fill in both 'how to' sections, though you must
X       fill in at least one 'how to' section.
X
X       If you leave a 'how to' section blank, include the '---' line, but
X       but having no command lines after it.
X
X    5) The program must be of original work.  All programs must be
X       in the public domain.  All copyrighted programs will be rejected.
X
X    6) Entries must be received between 16-Mar-90 0:00 GMT and 
X       26-May-90 0:00 GMT.  Email your entries to:
X	   
X	    ...!{sun,pacbell,uunet,utzoo,pyramid,amdahl}!hoptoad!obfuscate
X
X       We will attempt to Email a confirmation of receipt of contest
X       entries, however since Email is not reliable you may not receive it.
X       We regret that we can no longer accept entries via postal mail.
X
X    7) Each person may submit up to 8 entries.  Multiple entries must
X       be sent in separate Email letters.
X	
X    8) Entries that can not be built automatically in a portable makefile 
X       are not allowed.  (e.g., don't use #include "/dev/tty")
X
X    9) Starting this year, compiling entries must result an regular file
X       which can be executed. (No -o /dev/tty or similar compile lines)
X
X
XANNOUNCEMENT OF WINNERS:
X
X    * First announcement will likely be at the Summer 90 Usenix BOF.
X
X    * Winning entries will be posted in mid June 1990 to 
X      comp.sources.unix as well as news groups where these rules 
X      were posted.  (depending on the judges work load)
X    
X    * Winning entries will be deposited into the uunet archives.
X
X    * An article containing the winning entries will be published
X      in a future issue of the "Micro/Systems Journal".
X
X    * Winners receive international fame and flames!  :-)
X
X
XJUDGING:
X
X    Awards will be given to the best entry in a number of categories.
X    The actual category list will vary depending on the types of entries
X    we receive.  As a guide, consider using the following:
X
X	* The best small one line program
X	* The strangest source layout
X	* The most useful obfuscated program
X	* The most creatively obfuscated program
X	* Best obfuscated entry smaller than 256 bytes
X	* Best obfuscated entry smaller than 1024 bytes
X	* Best abuse of ANSI
X	* Worse abuse of the rules (no abuse of entry format please!)
X	* <anything else so strange that it deserves an award>
X
XPOINTS TO PONDER:
X
X    People are encouraged to examine winners of the previous
X    contests.  A copy of these entries was posted to
X    comp.sources.unix.  Contact the comp.sources.unix moderator, or
X    some archive site (such as uunet).  Keep in mind that rules
X    change from year to year, so some winning entries may not be
X    valid entries this year.  What was unique and novel one year
X    might be 'old' the next year.  In short, use your best judgment.
X
X    We examine each entry on several levels of confusion.  For example
X    each entry is judged when we:
X
X	* look at the original source
X	* run it through:  sed -e ',^#[	 ]*define,d' | /lib/cpp
X	* run it through:  sed -e ',^#[	 ]*include,d' | /lib/cpp
X	* run it through a C beautifier
X	* examine the algorithm
X	* compile and lint it
X	* execute it
X    
X    One line programs are best when they are short, obscure and concise.
X
X    We tend to dislike programs that:
X
X	* are very hardware specific
X	* are very OS or Un*x version specific
X	     (index/strchr differences are ok, but socket/streams specific 
X	      code is likely not to be)
X	* dump core or have compiler warnings
X	     (it is ok only if you warn us in the 'remark' header item)
X	* won't compile under both BSD or SYS V Un*x
X	* use an excessively long compile line to get around the size limit
X	* are longer than they need to be
X	* are similar to previous winners
X	* are similar to previous losers  :-)
X
X    Simply abusing #defines or -Dfoo=bar won't go as far as a program
X    that is more well rounded in confusion.
X
X    Unless you are cramped for space, or unless you are entering the 
X    'best one liner' category, we suggest that you format your program 
X    in a more creative way than simply forming excessively long lines.
X
X    We like programs that:
X
X	* are as concise and small as they need to be
X	* do something quasi-interesting
X	* pass lint without complaint (particularly strict ANSI ones)
X	* are portable
X	* are unique or novel in their obfuscation style
X	* MAKE USE OF A NUMBER OF DIFFERENT TYPES OF OBFUSCATION
X	* make us laugh and/or throw up  :-)
X
X    Some types of programs can't excel in some areas.  Of course, your 
X    program doesn't have to excel in all areas, but doing well in several 
X    areas really does help.
X
X    Be creative!
X
X    The Judging will be done by Landon Noll and Larry Bassel.  If you have
X    any QUESTIONS or COMMENTS, please feel free to send them to:
X
X	...!{sun,pacbell,uunet,pyramid,amdahl}!hoptoad!judges
X	judges at toad.com
X
X    however contest entries should be sent to: 
X    
X	...!{sun,pacbell,uunet,pyramid,amdahl}!hoptoad!obfuscate
X	obfuscate at toad.com
X
X
Xchongo <Landon Curt Noll> /\cc/\  	hoptoad!chongo
XLarry Bassel			  	{amdahl,ucbvax,cbosgd}|sun!lab
SHAR_EOF
$TOUCH -am 0922163990 1990/rules &&
chmod 0444 1990/rules ||
echo "restore of 1990/rules failed"
set `wc -c 1990/rules`;Wc_c=$1
if test "$Wc_c" != "8876"; then
	echo original size 8876, current size $Wc_c
fi
# ============= 1990/Makefile ==============
echo "x - extracting 1990/Makefile (Text)"
sed 's/^X//' << 'SHAR_EOF' > 1990/Makefile &&
X# %W% %G% %U%
X#
X# 1990 makefile
X
XSHELL=/bin/sh
XMAKE=make
XMAKEFLAGS=e
X
X# uncomment the line to select the preferred type of compile
X#
X# You should also check the ansi.mk or common.mk for the
X# proper compiler name and flags.
X#
X# NOTE ==> USE=ansi     compile with an ANSI compiler by default
X#USE=ansi
X# NOTE ==> USE=common   compile with a common K&R compiler by default
X#USE=common
X
XWINNERS=cmills pjr westley stig tbr db dds theorem baruch jaw scjones
X
Xall:
X	- at if [ "${USE}" = "common" ]; then \
X		echo ${MAKE} -k -f common.mk all; \
X		${MAKE} -k -f common.mk all; \
X	elif [ "${USE}" = "ansi" ]; then \
X		echo ${MAKE} -k -f ansi.mk all; \
X		${MAKE} -k -f ansi.mk all; \
X	else \
X		echo "set USE= in Makefile to be ansi or common as desired"; \
X		echo "or type: make -f ansi.mk for ansi makes"; \
X		echo "or type: make -f common.mk for common K&R makes"; \
X		exit 1; \
X	fi
X
Xansi:
X	${MAKE} -f ansi.mk all
X
Xcommon:
X	${MAKE} -f common.mk all
X
X${WINNERS}:
X	- at if [ "${USE}" = "common" ]; then \
X		echo ${MAKE} -k -f common.mk $@; \
X		${MAKE} -k -f common.mk $@; \
X	elif [ "${USE}" = "ansi" ]; then \
X		echo ${MAKE} -k -f ansi.mk $@; \
X		${MAKE} -k -f ansi.mk $@; \
X	else \
X		echo "set USE= in Makefile to be ansi or common as desired"; \
X		echo "or type: make -f ansi.mk for ansi makes"; \
X		echo "or type: make -f common.mk for common K&R makes"; \
X		exit 1;\
X	fi
X
Xclean:
X	${MAKE} -f ansi.mk clean
X	${MAKE} -f common.mk clean
Xclobber:
X	${MAKE} -f ansi.mk clobber
X	${MAKE} -f common.mk clobber
Xnuke: clobber
X	${MAKE} -f ansi.mk nuke
X	${MAKE} -f common.mk nuke
Xinstall:
X	${MAKE} -f ansi.mk install
X	${MAKE} -f common.mk install
SHAR_EOF
$TOUCH -am 0922165290 1990/Makefile &&
chmod 0444 1990/Makefile ||
echo "restore of 1990/Makefile failed"
set `wc -c 1990/Makefile`;Wc_c=$1
if test "$Wc_c" != "1622"; then
	echo original size 1622, current size $Wc_c
fi
# ============= 1990/ansi.mk ==============
echo "x - extracting 1990/ansi.mk (Text)"
sed 's/^X//' << 'SHAR_EOF' > 1990/ansi.mk &&
X# %W% %G% %U%
X#
X# 1990 makefile
X
XSHELL=/bin/sh
X
X# flags for ANSI compiles
X#
X# These flags are setup for gcc, change as/if needed
X#
XPEDANTIC=-pedantic
XCFLAGS=-O -ansi 
XCHMOD=chmod
XCC=gcc
XCP=cp
XRM=rm
XLN=ln
X
X# winners that may be ok to compile with ANSI
X#
XWINNERS=cmills pjr westley stig tbr dg baruch jaw scjones
X
Xall: ${WINNERS}
X
Xansi: all
X
Xcommon:
X	@echo "wrong makefile, use common.mk"
X	exit 1
X
Xcmills: cmills.c
X	${CC} ${CFLAGS} -DM=500 -DN=52 -DX="srand((int)time(0L))" -DV=void \
X	    -o cmills cmills.c
X
Xpjr: pjr.c
X	${CC} ${CFLAGS} pjr.c -o pjr
X
Xwestley: westley.c
X	${CC} ${CFLAGS} westley.c -o westley
X
Xstig: stig.c stig.ksh
X	@echo "run the Korn shell, and source stig.ksh"
X	@echo "or read stig.hint and create your own aliases"
X
Xscjones: scjones.c
X	${CC} ${CFLAGS} scjones.c -o scjones
X
Xtbr: tbr.c
X	${CC} ${CFLAGS} tbr.c -o tbr
X
Xdg: dg.c
X	${CC} ${CFLAGS} dg.c -Dindex=strchr -o dg
X	# compile with the following if you don't have strchr()
X	#${CC} ${CFLAGS} dg.c -o dg
X
Xdds: dds.c LANDER.BAS
X	${CC} ${CFLAGS} dds.c -o dds
X
Xtheorem: theorem.c
X	${CC} ${CFLAGS} theorem.c -o theorem
X	${RM} -f sorter.c
X	-./theorem -r 0 0 0 0 < theorem.c > sorter.c
X	${CC} ${CFLAGS} sorter.c -o sorter
X	${RM} -f fibonacci.c
X	-./sorter 0 0 0 0 < theorem.c > fibonacci.c
X	${CC} ${CFLAGS} fibonacci.c -o fibonacci
X
Xbaruch: baruch.c
X	${CC} ${CFLAGS} baruch.c -o baruch
X
Xjaw: jaw.c shark.sh
X	${RM} -f ./zcat ./atob ./jaw
X	${CC} ${CFLAGS} ${PEDANTIC} jaw.c -o zcat
X	${LN} zcat atob
X	echo 'PATH=;export PATH;atob|zcat' > jaw
X	${CHMOD} 0555 ./jaw
X
Xclean:
X	${RM} -f *.o a.out core
Xclobber: clean
X	${RM} -f ${WINNERS} sorter.c sorter
X	${RM} -f fibonacci.c fibonacci atob zcat
Xnuke: clobber
X	@true
Xinstall: all
X	cat ${WINNERS} > /dev/null
SHAR_EOF
$TOUCH -am 0922164990 1990/ansi.mk &&
chmod 0444 1990/ansi.mk ||
echo "restore of 1990/ansi.mk failed"
set `wc -c 1990/ansi.mk`;Wc_c=$1
if test "$Wc_c" != "1711"; then
	echo original size 1711, current size $Wc_c
fi
# ============= 1990/common.mk ==============
echo "x - extracting 1990/common.mk (Text)"
sed 's/^X//' << 'SHAR_EOF' > 1990/common.mk &&
X# %W% %G% %U%
X#
X# 1990 makefile
X
XSHELL=/bin/sh
XCHMOD=chmod
XCC=gcc
XCP=cp
XRM=rm
XSED=sed
XLN=ln
X
X# flags for common K&R compiles
X#
XCFLAGS=-O
XCC=cc
X
X# winners that may be ok to compile with common K&R
X#
XWINNERS=cmills pjr westley tbr dg dds theorem baruch jaw scjones
X
Xall: ${WINNERS}
X
Xansi:
X	@echo "wrong makefile, use ansi.mk"
X	exit 1
X
Xcommon: all
X
Xcmills: cmills.c
X	${CC} ${CFLAGS} -DM=500 -DN=52 -DX="srand((int)time(0L))" -DV=int \
X	    -o cmills cmills.c
X
Xpjr: pjr.c
X	${CC} ${CFLAGS} pjr.c -o pjr
X
Xwestley: westley.alt.c
X	${CC} ${CFLAGS} westley.alt.c -o westley
X
Xwestley.alt.c: westley.c
X	${RM} -f westley.alt.c
X	-${SED} -e 's/signed//' -e 's/1s/1/g' -e 's/^	#/#/' \
X	    westley.c > westley.alt.c
X
Xstig: stig.c stig.ksh
X	@echo "run the Korn shell, and source stig.ksh"
X	@echo "or read stig.hint and create your own aliases"
X
Xtbr: tbr.c
X	${CC} ${CFLAGS} tbr.c -o tbr
X
Xdg: dg.c
X	${CC} ${CFLAGS} dg.c -Dindex=strchr -o dg
X	# compile with the following if you don't have strchr()
X	#${CC} ${CFLAGS} dg.c -o dg
X
Xdds: dds.c LANDER.BAS
X	${CC} ${CFLAGS} dds.c -o dds
X
Xtheorem: theorem.c
X	${CC} ${CFLAGS} theorem.c -o theorem
X	${RM} -f sorter.c
X	-./theorem -r 0 0 0 0 < theorem.c > sorter.c
X	${CC} ${CFLAGS} sorter.c -o sorter
X	${RM} -f fibonacci.c
X	-./sorter 0 0 0 0 < theorem.c > fibonacci.c
X	${CC} ${CFLAGS} fibonacci.c -o fibonacci
X
Xbaruch: baruch.c
X	${CC} ${CFLAGS} baruch.c -o baruch
X
Xjaw: jaw.c
X	${RM} -f ./zcat ./atob ./jaw
X	${CC} ${CFLAGS} jaw.c -o zcat
X	${LN} zcat atob
X	echo 'PATH=;export PATH;atob|zcat' > jaw
X	${CHMOD} 0555 ./jaw
X
Xscjones: scjones.alt.c stdlib.h
X	${CC} ${CFLAGS} -I. scjones.alt.c -o scjones
X
X# NOTE: scjones.alt.c is just a de-ANSI-fied scjones.c for example only
X#
Xscjones.alt.c: scjones.c
X	${RM} -f scjones.alt.c
X	-${SED} -e 's#??/#\\#g' -e 's/??=/#/g' -e 's/??(/[/g' -e 's/??)/]/g' \
X		-e "s/??'/^/g" -e 's/??</{/g' -e 's/??!/|/g' -e 's/??>/}/g' \
X		-e 's/??-/~/g' scjones.c > scjones.alt.c
X
Xstdlib.h:
X	${RM} -f stdlib.h
X	echo "#define EXIT_SUCCESS 0" >stdlib.h
X	echo "#define EXIT_FAILURE 1" >>stdlib.h
X	echo "void exit(); /* may need to be int on some systems */" >>stdlib.h
X
Xclean:
X	rm -f *.o a.out core
Xclobber: clean
X	${RM} -f ${WINNERS} sorter.c sorter westley.alt.c stdlib.h
X	${RM} -f fibonacci.c fibonacci atob zcat scjonds.alt.c
Xnuke: clobber
X	@true
Xinstall: all
X	cat ${WINNERS} > /dev/null
SHAR_EOF
$TOUCH -am 0922164990 1990/common.mk &&
chmod 0444 1990/common.mk ||
echo "restore of 1990/common.mk failed"
set `wc -c 1990/common.mk`;Wc_c=$1
if test "$Wc_c" != "2327"; then
	echo original size 2327, current size $Wc_c
fi
# ============= 1990/baruch.c ==============
echo "x - extracting 1990/baruch.c (Text)"
sed 's/^X//' << 'SHAR_EOF' > 1990/baruch.c &&
Xv,i,j,k,l,s,a[99];
Xmain()
X{
X	for(scanf("%d",&s);*a-s;v=a[j*=v]-a[i],k=i<s,j+=(v=j<s&&(!k&&!!printf(2+"\n\n%c"-(!l<<!j)," #Q"[l^v?(l^j)&1:2])&&++l||a[i]<s&&v&&v-i+j&&v+i-j))&&!(l%=s),v||(i==j?a[i+=k]=0:++a[i])>=s*k&&++a[--i])
X		;
X}
SHAR_EOF
$TOUCH -am 0922163990 1990/baruch.c &&
chmod 0444 1990/baruch.c ||
echo "restore of 1990/baruch.c failed"
set `wc -c 1990/baruch.c`;Wc_c=$1
if test "$Wc_c" != "231"; then
	echo original size 231, current size $Wc_c
fi
# ============= 1990/cmills.c ==============
echo "x - extracting 1990/cmills.c (Text)"
sed 's/^X//' << 'SHAR_EOF' > 1990/cmills.c &&
X#include<stdio.h>
X#include<time.h>
X#define S(q)B(*e=0),q,p);
X#define W(w)if((w)<22)v= -v;else v-=10;else
X#define F for(r=d;r<d+N;
X#define H(v,g)v=h(v,*g++= *r++),*g=0;
X#define B(n)b(l,n),(V)printf(l
XV
Xexit();char*g,c[M],d[N],q[N],p[N],*e,*r=d+N,l[M],*t="??",*k,*m="DEATHISDSev2oinpohae3ttsluuln4a?uibfe 5l\0rtlfrb6 ?a?el:e7$!n\0?e t8%ccp\0.%s9deelc.s T.@?-t.\t<J /\0=a\nP=Q Sex \0l KW Sin a$\0ane-lay% ge#-slediefuk ar  r$via-:o ?+}:r? n \0:) ee%lone 1-esy666!-~v\n.!^`'~@#\0\np~===:=q";b(o,n)char*o;{for(k=n+m;*o++=*k;k+=9);}int
Xy=M*2,v,x,s,f,j,o;u(s){B(s));if(!gets(l))exit(0);return(o=
X*l)=='y'||o=='Y'||o!='n'&&o!='N'&&u(s);}h(v,m){for(k=c;*k!='J';)if(m==*k++)break;m=k-c;if(v<0)W(v=m-v)
Xif(m==1)W(v+=11)
Xv+=m;return
Xv;}main(w,z)char**z;{b(c,2)*X;for(--w&&(y=atoi(1[z]));y>1;){if(r-d>N*3/4){B(8));F++r)*r=c[(r-d)%13];F)w=
X*(g=d+rand()%N),*g=
X*r,*r++=w;r=d;}for(;;){B(3),y);if(!gets(l)||(w=atoi(l))<1)exit(0);if(w&1||w>M||w>y)B(1),y<M?y:M);else
Xbreak;}y-=w,s=f=j=x=v=0,g=q,e=p;H(x,g)H(x,g)H(v,e)H(v,e)*t=
X*q;S(t)*q=='A'&&y>=w/2&&u(5)&&(y+=(3*(h(0,1[q])==10)-1)*w/2);if(x==-21)goto
X_;if(v==-21){y+=w/2;goto
X_;}while(x>-17&&x<17)H(x,g)while((v==20||*p==-1[e])&&y>=w&&u(6)){y-=w;++s;for(g=e++;2[g]=
X*g,g!=p;)--g;*g++=
X*e;*g=' ';i:v=h(h(0,*p),*e++=
X*r++);S(t)if(*p=='A'&&-1[e]!=
X*p)goto
X_;}if(f=y>=w&&u(7))y-=w,H(v,e)while(!f&&v<22&&u(4)){H(v,e)if(v<22)S(t)}_:x<0&&(x=
X-x);v<0&&(v=
X-v);if(v<22)if(v==x)j+=w*++f;else
Xif(x>21||v>x)j+=w*2*++f;if(s--){*e++=' ';*e++=
X*p;*e=0;for(e=p;*e=2[e];)e++;goto
Xi;}y+=j;S(q)};}
SHAR_EOF
$TOUCH -am 0922163990 1990/cmills.c &&
chmod 0444 1990/cmills.c ||
echo "restore of 1990/cmills.c failed"
set `wc -c 1990/cmills.c`;Wc_c=$1
if test "$Wc_c" != "1512"; then
	echo original size 1512, current size $Wc_c
fi
# ============= 1990/dds.c ==============
echo "x - extracting 1990/dds.c (Text)"
sed 's/^X//' << 'SHAR_EOF' > 1990/dds.c &&
X#define O(b,f,u,s,c,a)b(){int o=f();switch(*p++){X u:_ o s b();X c:_ o a b();default:p--;_ o;}}
X#define t(e,d,_,C)X e:f=fopen(B+d,_);C;fclose(f)
X#define U(y,z)while(p=Q(s,y))*p++=z,*p=' '
X#define N for(i=0;i<11*R;i++)m[i]&&
X#define I "%d %s\n",i,m[i]
X#define X ;break;case
X#define _ return
X#define R 999
Xtypedef char*A;int*C,E[R],L[R],M[R],P[R],l,i,j;char B[R],F[2];A m[12*R],malloc
X(),p,q,x,y,z,s,d,f,fopen();A Q(s,o)A s,o;{for(x=s;*x;x++){for(y=x,z=o;*z&&*y==
X*z;y++)z++;if(z>o&&!*z)_ x;}_	0;}main(){m[11*R]="E";while(puts("Ok"),gets(B)
X)switch(*B){X'R':C=E;l=1;for(i=0;i<R;P[i++]=0);while(l){while(!(s=m[l]))l++;if
X(!Q(s,"\"")){U("<>",'#');U("<=",'$');U(">=",'!');}d=B;while(*F=*s){*s=='"'&&j
X++;if(j&1||!Q(" \t",F))*d++=*s;s++;}*d--=j=0;if(B[1]!='=')switch(*B){X'E':l=-1
XX'R':B[2]!='M'&&(l=*--C)X'I':B[1]=='N'?gets(p=B),P[*d]=S():(*(q=Q(B,"TH"))=0,p
X=B+2,S()&&(p=q+4,l=S()-1))X'P':B[5]=='"'?*d=0,puts(B+6):(p=B+5,printf("%d\n",S
X()))X'G':p=B+4,B[2]=='S'&&(*C++=l,p++),l=S()-1 X'F':*(q=Q(B,"TO"))=0;p=B+5;P[i
X=B[3]]=S();p=q+2;M[i]=S();L[i]=l X'N':++P[*d]<=M[*d]&&(l=L[*d]);}else p=B+2,P[
X*B]=S();l++;}X'L':N printf(I)X'N':N free(m[i]),m[i]=0	X'B':_ 0 t('S',5,"w",N
Xfprintf(f,I))t('O',4,"r",while(fgets(B,R,f))(*Q(B,"\n")=0,G()))X 0:default:G()
X;}_ 0;}G(){l=atoi(B);m[l]&&free(m[l]);(p=Q(B," "))?strcpy(m[l]=malloc(strlen(p
X)),p+1):(m[l]=0,0);}O(S,J,'=',==,'#',!=)O(J,K,'<',<,'>',>)O(K,V,'$',<=,'!',>=)
XO(V,W,'+',+,'-',-)O(W,Y,'*',*,'/',/)Y(){int o;_*p=='-'?p++,-Y():*p>='0'&&*p<=
X'9'?strtol(p,&p,0):*p=='('?p++,o=S(),p++,o:P[*p++];}
SHAR_EOF
$TOUCH -am 0922163990 1990/dds.c &&
chmod 0444 1990/dds.c ||
echo "restore of 1990/dds.c failed"
set `wc -c 1990/dds.c`;Wc_c=$1
if test "$Wc_c" != "1536"; then
	echo original size 1536, current size $Wc_c
fi
# ============= 1990/dg.c ==============
echo "x - extracting 1990/dg.c (Text)"
sed 's/^X//' << 'SHAR_EOF' > 1990/dg.c &&
X#include <stdio.h>
X
X#define d define
X
X#d b12(x) 12 x
X#d a13(x) x 13
X#d a16(x) x 16
X#d a32(x) x 32
X#d acb(x) x]
X#d acc(x) x}
X#d aco(x) x:
X#d bco(x) :x
X#d acp(x) x)
X#d bef(x) EOF x
X#d aeq(x) x=
X#d afo(x) x for
X#d age(x) x fgetc
X#d asi(x) x stdin
X#d aso(x) x stdout
X#d bgt(x) >x
X#d ai(x) x i
X#d aj(x) x j
X#d al(x) x l
X#d ami(x) x-
X#d bne(x) !=x
X#d aob(x) x[
X#d aop(x) x(
X#d apl(x) x+
X#d bpu(x) fputc x
X#d bqm(x) ?x
X#d aqm(x) x?
X#d aqu(x) x'
X#d ase(x) x;
X#d awh(x) x while
X#d axo(x) x^
X#d a0(x) x 0
X#d b13(x) 13 x
X#d b16(x) 16 x
X#d b19(x) 19 x
X#d b48(x) 48 x
X#d a64(x) x 64
X#d b66(x) 66 x
X#d bcb(x) ]x
X#d bch(x) char x
X#d bcm(x) ,x
X#d acm(x) x,
X#d bcp(x) )x
X#d beq(x) =x
X#d bex(x) extern x
X#d bi(x) i x
X#d bin(x) int x
X#d bix(x) index x
X#d bj(x) j x
X#d bl(x) l x
X#d alt(x) x<
X#d bma(x) main x
X#d bob(x) [x
X#d boc(x) {x
X#d bop(x) (x
X#d bpl(x) +x
X#d app(x) x++
X#d bqu(x) 'x
X#d bse(x) ;x
X#d bst(x) *x
X 
Xbma(acp(bop(app(bcp(ai(boc(ase(bch(a16(bl(alt(bob(ai(b66(ase(bcb(a0(bcm(aeq(bst(acb(bj(a64(bse(aob(bin(al(bi(aeq(bse(ai(bex(aop(bch(afo(bst(ase(bix(())))))))))))))))))))))))))))))))))))))))
Xbl(ai(bob(aob(bi(al(bcb(aop(beq(apl(b13(a13(bpl(aeq(bop(acb(bl(bob(a32(bi(bpl(apl(b16(bcb(ai(beq(b19(aob(bpl(bop(l))))))))))))))))))))))))))))))
Xbpl(acp(b48(acp(asi(bcb(aop(beq(age(bop(aeq(bi(ai(bgt(aop(b12(aop(bqm(awh(b12(ase(bco(acp(bi(acp(bcp(acp(bpl(aqu(bqu(A))))))))))))))))))))))))))))))
Xbne(acc(bef(ase(bcp(acp(aso(bpu(acm(ai(bop(aco(bop(acb(bj(al(beq(ami(bix(aj(axo(bop(a16(aob(bl(al(aqm(bcm(acp(acp(i))))))))))))))))))))))))))))))
SHAR_EOF
$TOUCH -am 0922163990 1990/dg.c &&
chmod 0444 1990/dg.c ||
echo "restore of 1990/dg.c failed"
set `wc -c 1990/dg.c`;Wc_c=$1
if test "$Wc_c" != "1526"; then
	echo original size 1526, current size $Wc_c
fi
# ============= 1990/jaw.c ==============
echo "x - extracting 1990/jaw.c (Text)"
sed 's/^X//' << 'SHAR_EOF' > 1990/jaw.c &&
X#define C char
X#define F X,perror("oops"),1
X#define G getchar()
X#define I ;if(
X#define P putchar
X#define Q 256
X#define W ;while(
X#define X return 0
X#include<stdio.h>
Xlong M,N,c,f,m,o,r,s,w;y(l){o^=l;m+=l+1;f=f*2+l+(f>>31&1);}int
XO,S,e,i,k,n,q,t[69001];b(g){k=4 W g<k)y(P((C)(w>>--k*8)&255));w=0;}C D[Q*Q],h
X[Q*Q];main(g,V)C**V;{I**V-97)X,a()W G-10)W(g=G)+1&&g-'x')if(g-10){I
X4<k)b(0)I g>32&g<'v')w=w*85+g-33,++k;else{I
Xg-'z'|k)F;w=0;k=5;}}W G-78)I scanf("%ld%lx E%lx S%lx R%lx ",&M,&N,&c,&s,&r)-5)F
XI M){b(g=3-(M-1&3))W g--)y(0);}I(M-N|c-o|s-m|r-f)&4294967295)F;X;}long
Xg(){C*p I m<f&n<k&&(m=(1L<<++n)-1)||O>=S){O=0;S=fread(D,1,n,stdin)*8 I
XS<8)X-1;S-=n-1;}p=D+O/8;q=O&7;O+=n;X,(1<<8-q)-1&*p>>q|m&((15<n+q)*p[2]*Q|p[1]&
X255)<<8-q;}a(){C*p=D+Q;G;G;k=G;e=k>>7&1;k&=31 I k>16)F;w=Q
XW w--)t[w]=0,h[w]=w;n=8;f=Q+e;i=o=w=g()I o<0)X,1;P(i)W(w=g())+1){I
Xw==Q&e){W w--)t[w]=0;m=n=8;f=Q I(w=g())<0)X;}c=w
XI w>=f)*p++=i,w=o W w>=Q)*p++=h[w],w=t[w];P(i=h[w])W
Xp>D+Q)P(*--p)I(w=f)<1L<<k)t[w]=o,h[f++]=i;o=c;}X;}
SHAR_EOF
$TOUCH -am 0922163990 1990/jaw.c &&
chmod 0444 1990/jaw.c ||
echo "restore of 1990/jaw.c failed"
set `wc -c 1990/jaw.c`;Wc_c=$1
if test "$Wc_c" != "999"; then
	echo original size 999, current size $Wc_c
fi
# ============= 1990/pjr.c ==============
echo "x - extracting 1990/pjr.c (Text)"
sed 's/^X//' << 'SHAR_EOF' > 1990/pjr.c &&
X#include <stdio.h>
X#define A(a) G a();
X#define B(a) G (*a)();
X#define C(a,b) G a() { printf(b); return X; }
Xtypedef struct F G;A(a)A(b)A(c)A(d)A(e)A(f)A(g)A(h)A(i)A(j)A(k)A(l)A(m)A(n)A(
Xo)A(p)A(q)A(r)A(s)A(t)A(u)A(v)A(w)A(x)A(y)A(z)A(S)A(N)void Q();struct F{B(a)B
X(b)B(c)B(d)B(e)B(f)B(g)B(h)B(i)B(j)B(k)B(l)B(m)B(n)B(o)B(p)B(q)B(r)B(s)B(t)B(
Xu)B(v)B(w)B(x)B(y)B(z)B(S)B(N)void(*Q)();}X={a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,
Xq,r,s,t,u,v,w,x,y,z,S,N,Q};C(a,"z")C(b,"y")C(c,"x")C(d,"w")C(e,"v")C(f,"u")C(
Xg,"t")C(h,"s")C(i,"r")C(j,"q")C(k,"p")C(l,"o")C(m,"n")C(n,"m")C(o,"l")C(p,"k"
X)C(q,"j")C(r,"i")C(s,"h")C(t,"g")C(u,"f")C(v,"e")C(w,"d")C(x,"c")C(y,"b")C(z,
X"a")C(S," ")C(N,"\n") void Q(){}main(){X=g().s().v().S().j().f().r().x().p().
XS().y().i().l().d().m().S().u().l().c().S().q().f().n().k().v().w().S().l().e
X().v().i().S().g().s().v().S().o().z().a().b().S().w().l().t().N();}
SHAR_EOF
$TOUCH -am 0922163990 1990/pjr.c &&
chmod 0444 1990/pjr.c ||
echo "restore of 1990/pjr.c failed"
set `wc -c 1990/pjr.c`;Wc_c=$1
if test "$Wc_c" != "879"; then
	echo original size 879, current size $Wc_c
fi
# ============= 1990/scjones.c ==============
echo "x - extracting 1990/scjones.c (Text)"
sed 's/^X//' << 'SHAR_EOF' > 1990/scjones.c &&
Xchar*a??(??)=??<
X"??=include<stdio.h>",
X"??=include<stdlib.h>",
X"??=define o stdout",
X"??=define b break;case",
X"??=define s(p)fputs(p,o);",
X"??=define c(p)fputc(p,o);",
X"void t(p,f)char*p;??<f&&c('??/"')",
X"for(;;p++)??<switch(*p)??<case 0:f&&",
X"s(??/"??/??/??/",??/")c('??/??/n')return;case",
X"'??=':s(??/"???/??/?=??/")b'??<':s(??/"???/??/?<??/")",
X"b'??>':s(??/"???/??/?>??/")b'??(':s(??/"???/??/?(??/")b'??)'",
X":s(??/"???/??/?)??/")b'??/??/??/??/':f&&s(??/"???/??/?/??/")",
X"s(??/"???/??/?/??/")b'??/??/n':if(f)s(??/"???/??/?/n??/")",
X"else case'??/"':if(f)s(??/"???/??/?/??/??/??/"??/")",
X"else default:c(*p)??>??>??>main()??<char**p",
X";t(??/"char*a??(??)=??<??/",0);for(p=a;*p",
X";p++)t(*p,1);t(??/"0??>;??/",0);for(p=a",
X";*p;p++)t(*p,0);exit(!ferror(o)&&",
X"!fclose(o)?EXIT_SUCCESS",
X":EXIT_FAILURE);",
X"/*NOTREACHED*/",
X"??>",
X0??>;
X??=include<stdio.h>
X??=include<stdlib.h>
X??=define o stdout
X??=define b break;case
X??=define s(p)fputs(p,o);
X??=define c(p)fputc(p,o);
Xvoid t(p,f)char*p;??<f&&c('"')
Xfor(;;p++)??<switch(*p)??<case 0:f&&
Xs("??/",")c('??/n')return;case
X'??=':s("???/?=")b'??<':s("???/?<")
Xb'??>':s("???/?>")b'??(':s("???/?(")b'??)'
X:s("???/?)")b'??/??/':f&&s("???/?/")
Xs("???/?/")b'??/n':if(f)s("???/?/n")
Xelse case'"':if(f)s("???/?/??/"")
Xelse default:c(*p)??>??>??>main()??<char**p
X;t("char*a??(??)=??<",0);for(p=a;*p
X;p++)t(*p,1);t("0??>;",0);for(p=a
X;*p;p++)t(*p,0);exit(!ferror(o)&&
X!fclose(o)?EXIT_SUCCESS
X:EXIT_FAILURE);
X/*NOTREACHED*/
X??>
SHAR_EOF
$TOUCH -am 0922163990 1990/scjones.c &&
chmod 0444 1990/scjones.c ||
echo "restore of 1990/scjones.c failed"
set `wc -c 1990/scjones.c`;Wc_c=$1
if test "$Wc_c" != "1474"; then
	echo original size 1474, current size $Wc_c
fi
# ============= 1990/stig.c ==============
echo "x - extracting 1990/stig.c (Text)"
sed 's/^X//' << 'SHAR_EOF' > 1990/stig.c &&
Xc
SHAR_EOF
$TOUCH -am 0922163990 1990/stig.c &&
chmod 0444 1990/stig.c ||
echo "restore of 1990/stig.c failed"
set `wc -c 1990/stig.c`;Wc_c=$1
if test "$Wc_c" != "2"; then
	echo original size 2, current size $Wc_c
fi
# ============= 1990/tbr.c ==============
echo "x - extracting 1990/tbr.c (Text)"
sed 's/^X//' << 'SHAR_EOF' > 1990/tbr.c &&
X
X#define D ,close(
X
Xchar              *c,q              [512              ],m[              256
X],*v[           99], **u,        *i[3];int         f[2],p;main       (){for
X (m[m        [60]=   m[62      ]=32   ]=m[*      m=124   [m]=       9]=6;
X  e(-8)     ,gets      (1+(    c=q)     )||      exit      (0);     r(0,0)
X   )for(    ;*++        c;);  }r(t,      o){    *i=i        [2]=    0;for
X     (u=v  +98           ;m[*--c]         ^9;m [*c]          &32  ?i[*c
X       &2]=                *u,u-             v^98              &&++u:
X
X	3	)if(!m[*c]){for(*++c=0;!m[*--c];);
X	*	--u= ++c;}u-v^98?strcmp(*u,"cd")?*c?pipe(f),o=f[
X	1	]:
X	4	,(p=fork())?e(p),o?r(o,0)D o)D*f):
X	1	,wait(0):(o?dup2(*f,0)D*f)D o):*i?
X	5	D 0),e(open(*i,0)):
X	9	,t?dup2(t,1)D t):i[
X	2	]?
X	6	D 1),e(creat(i[2],438)):
X	5	,e(execvp(*u,u))):e(chdir(u[1])*2):
X	3	;}e(x){x<0?write(2,"?\n$ "-x/4,2),x+1||exit(1):
X	5	;}
SHAR_EOF
$TOUCH -am 0922163990 1990/tbr.c &&
chmod 0444 1990/tbr.c ||
echo "restore of 1990/tbr.c failed"
set `wc -c 1990/tbr.c`;Wc_c=$1
if test "$Wc_c" != "886"; then
	echo original size 886, current size $Wc_c
fi
# ============= 1990/theorem.c ==============
echo "x - extracting 1990/theorem.c (Text)"
sed 's/^X//' << 'SHAR_EOF' > 1990/theorem.c &&
X#include <stdio.h>
X#include <math.h>
X#define X
X#define Y {}
X#define C  }
X#define o {
X#undef main
Xchar m[500][99],v[99],R;
Xint*a,b,n,i,j,W,A;
Xfloat Q,G,D,M,T,B,O,U,V,N,y,e();
XP(g,R,u)float*g,R,u;{int c;for(*g=1,c=u;c--;*g*=R);}
XX
XK(g,R,u)float*g,u;char R;
Xo
Xif(R=='+')*g+=u;
Xif(R=='-')*g-=u;
Xif(R=='*')*g*=u;
Xif(R=='/')*g/=u;
Xif(R=='^')P(g,*g,u);
XC
Xw(g,R,u)float*g,u;char R;
X/**/{int b,f;A=atoi(*++a);b=atoi(*++a);while((f=A+b)<15000){printf("%d\n",f);A=b;b=f;}}
Xmain(A,a)int A;char*a[];
Xo o
Xif(!strcmp(*++a,"-r"))S();
XD=atof(*++a);
XT=atof(*++a);
XB=atof(*++a);
XM=atof(*(4+(a-=3)));
XC
Xwhile(D<T)
Xo
XU=e((G=B/2,*a),D,M,a);
XV=e(*a,Q=D+G,M+G*U,a);
X/*/
Xz;/*/
XN=2*e(*a,Q,M+G*V,a);
XM+=B*V/3+B*N/6+B*e(*a,D+=B,M+G*N,a)/6+G*U/3;
Xprintf("%f %f\n",D,M);
XC
Xwhile(T=0)
X;
XW=D=1;
X;
Xwhile(W!=1)
Xo o
Xstrcpy(j+m,v);
Xo 
Xif((j-=W)<=W)break;
Xstrcpy(j+m,m+j-W);
XC
Xwhile(strcmp(m+j-W,v)>0)
Xj=i;
Xstrcpy(v,i+m);
XC
Xfor(i=(W/=3)-1;++i<n;)
X;
XC
Xdo
X;
Xwhile(0);
Xfor(W=1;(W=W*3+1)<n;);
XC
Xfloat e(f,D,M,a)char*f,*a[];float D,M;
Xo
X#define main L
XO=0;
XR='+';
Xfor(;*f;f++)
Xif(*f=='y')K(&O,R,M);
Xelse if((*f>='0')&&(*f<='9'))K(&O,R,(float)*f-'0');
Xelse if(*f=='x')K(&O,R,D);
Xelse if(1)R=*f;
Xif(1);
Xreturn O;
Xfor(j=0;j<n;puts(j++[m]));
Xe("",O,&O,a);
Xn=j-(O=1);
Xwhile(gets(j++[m]));
Xif(!strcmp(*++a,"-r"))S();
XC
X/**/main(A,a)int A;char*a[];
XY
XS(){while(gets(b++[m]));for(b--;b--;puts(b[m]));}
Xchar*f,m[500][99],R,v[99];
Xint b,W,n,i,j,z;
Xfloat Q,G,D,M,T,O,B,U,V,N,e();
X#define Y
X#define X {}
X#define o }
X#define C {
X#include <stdio.h>
X#include <math.h>
SHAR_EOF
$TOUCH -am 0922163990 1990/theorem.c &&
chmod 0444 1990/theorem.c ||
echo "restore of 1990/theorem.c failed"
set `wc -c 1990/theorem.c`;Wc_c=$1
if test "$Wc_c" != "1511"; then
	echo original size 1511, current size $Wc_c
fi
# ============= 1990/westley.c ==============
echo "x - extracting 1990/westley.c (Text)"
sed 's/^X//' << 'SHAR_EOF' > 1990/westley.c &&
Xchar*lie;
X
X	double time, me= !0XFACE,
X
X	not; int rested,   get, out;
X
X	main(ly, die) char ly, **die ;{
X
X	    signed char lotte,
X
X
Xdear; (char)lotte--;
X
X	for(get= !me;; not){
X
X	1 -  out & out ;lie;{
X
X	char lotte, my= dear,
X
X	**let= !!me *!not+ ++die;
X
X	    (char*)(lie=
X
X
X"The gloves are OFF this time, I detest you, snot\n\0sed GEEK!");
X
X	do {not= *lie++ & 0xF00L* !me;
X
X	#define love (char*)lie -
X
X	love 1s *!(not= atoi(let
X
X	[get -me?
X
X	    (char)lotte-
X
X
X(char)lotte: my- *love -
X	
X	'I'  -  *love -  'U' -
X
X	'I'  -  (long)  - 4 - 'U' ])- !!
X	
X	(time  =out=  'a'));} while( my - dear
X
X	&& 'I'-1l  -get-  'a'); break;}}
X
X	    (char)*lie++;
X
X
X(char)*lie++, (char)*lie++; hell:0, (char)*lie;
X
X	get *out* (short)ly   -0-'R'-  get- 'a'^rested;
X
X	do {auto*eroticism,
X
X	that; puts(*( out
X
X	    - 'c'
X	
X-('P'-'S') +die+ -2 ));}while(!"you're at it");
X
X
Xfor (*((char*)&lotte)^=
X
X	(char)lotte; (love ly) [(char)++lotte+
X
X	!!0xBABE];){ if ('I' -lie[ 2 +(char)lotte]){ 'I'-1l ***die; }
X
X	else{ if ('I' * get *out* ('I'-1l **die[ 2 ])) *((char*)&lotte) -=
X
X	'4' - ('I'-1l); not; for(get=!
X
X
Xget; !out; (char)*lie  &  0xD0- !not) return!!
X
X	(char)lotte;}
X
X
X(char)lotte;
X
X	do{ not* putchar(lie [out
X
X	*!not* !!me +(char)lotte]);
X
X	not; for(;!'a';);}while(
X
X	    love (char*)lie);{
X
X
Xregister this; switch( (char)lie
X
X	[(char)lotte] -1s *!out) {
X
X	char*les, get= 0xFF, my; case' ':
X
X	*((char*)&lotte) += 15; !not +(char)*lie*'s';
X
X	this +1s+ not; default: 0xF +(char*)lie;}}}
X
X	get - !out;
X
X	if (not--)
X
X	goto hell;
X
X	    exit( (char)lotte);}
SHAR_EOF
$TOUCH -am 0922163990 1990/westley.c &&
chmod 0444 1990/westley.c ||
echo "restore of 1990/westley.c failed"
set `wc -c 1990/westley.c`;Wc_c=$1
if test "$Wc_c" != "1529"; then
	echo original size 1529, current size $Wc_c
fi
# ============= 1990/baruch.hint ==============
echo "x - extracting 1990/baruch.hint (Text)"
sed 's/^X//' << 'SHAR_EOF' > 1990/baruch.hint &&
XBest Small Program: <baruch at genius.tau.ac.il> Osovlanski & Nissenbaum
X
X	Doron Osovlanski
X	CADTECH - CAD/CAM Systems Ltd
X        24 Ben-Yosef st.
X        Givat-Shmuel   51905
X	Israel
X
X	Baruch Nissenbaum                  BARUCH at TAUNIVM.TAU.AC.IL
X	Tel-Aviv University
X	The Faculty of Engineering
X	Tel-Aviv
X	Israel
X
X
XJudges' comments:
X
X    Compile.  Try:
X
X	echo 4 | baruch
X	echo 7 | baruch
X
X    This program reads an integer between 4 and 99 from the stdin.
X
X    NOTE: The original program did not have a newline at the end of
X	  the file.  We added a final newline to the file to make
X	  unpacking easy.
X
X
XSelected notes from the author:
X
X    The goal of this work was to write a program that solves the
X    classic n-queen problem, with a board size of up to 99x99, while
X    keeping the program as short as possible.
X
X    The program finds all possibilities to place N chess queens on
X    a NxN chess board so that no queen is in range of any other queen
X    (not in the same column row or diagonal).  For each solution the
X    chess board and the place of the queens is printed to stdout.
X
X
X    This program is about as simple and as readable as possible.
X    To make things even more simple we used a very limited subset of C:
X
X	     No pre-processor statements
X	     Only one, harmless, 'for' statement
X	     No ifs
X	     No breaks
X	     No cases
X	     No functions
X	     No gotos
X	     No structures
X
X    In short, it contains no C language that might confuse the
X    innocent reader.  :-)
X
X
X    This program demonstrates the claim that in C, any program
X    can be written using a single 'for' statement, as long as it is
X    long enough..
X
XThe authors further note:
X
X    For PC users:
X    In order to compile the program under Turbo-C or MSC, 'int '
X    should be inserted at the beginning of the program.
X    For better looking results it is recommended to replace the " #Q"
X    string with " \261\2".
SHAR_EOF
$TOUCH -am 0922163990 1990/baruch.hint &&
chmod 0444 1990/baruch.hint ||
echo "restore of 1990/baruch.hint failed"
set `wc -c 1990/baruch.hint`;Wc_c=$1
if test "$Wc_c" != "1908"; then
	echo original size 1908, current size $Wc_c
fi
# ============= 1990/cmills.hint ==============
echo "x - extracting 1990/cmills.hint (Text)"
sed 's/^X//' << 'SHAR_EOF' > 1990/cmills.hint &&
XBest Game: <cmills at wyse.com> Chris Mills
X
X	Chris Mills
X	Wyse Technology
X	3471 N. 1st St.
X	San Jose CA 95134
X	USA
X
X
XJudges notes:
X
X    Compile notes:
X
X       cc -DM=500 -DN=52 -DX="srand((int)time(0L))" -DV=void -o cmills cmills.c
X
X	-DM=<max bet allowed>
X	-DN=<52 * number of decks used>
X	-DX=<how to seed the rand() generator>
X	-DV=<void ot int>
X
X    Usage: cmills [starting_cash]
X
X
XSelected notes from the author:
X
X    This is a blackjack program.  It does splits, doubling down,
X    insurance, etc.  
X
X    As best I can figure, it should be ANSI-compliant, as well as
X    portable to BSD & sysV (as well as the irritating compiler I
X    was using which assumes x=*p++ means x*=p++!).  It is
X    reasonably robust in its error handling---it won't let you
X    split, double, etc. unless you actually have the cash, etc.  To
X    terminate the program, hit EOF or type 0 or a negative number
X    for you wager.
X
X    The way it deals with splits is particularly cool (IMHO).  You
X    can split many times, and it will show all hands as they are
X    played.
SHAR_EOF
$TOUCH -am 0922163990 1990/cmills.hint &&
chmod 0444 1990/cmills.hint ||
echo "restore of 1990/cmills.hint failed"
set `wc -c 1990/cmills.hint`;Wc_c=$1
if test "$Wc_c" != "1054"; then
	echo original size 1054, current size $Wc_c
fi
# ============= 1990/dds.hint ==============
echo "x - extracting 1990/dds.hint (Text)"
sed 's/^X//' << 'SHAR_EOF' > 1990/dds.hint &&
XBest Language Tool: <dds at cc.ic.ac.uk> Diomidis Spinellis
X
X	Diomidis Spinellis
X	Imperial College, University of London
X	Myrsinis 1
X	GR-145 62 Kifissia
X	Greece
X
X
XJudges' comments:
X
X    Compile and run.  Give the following lines as input:
X    
X	OLD LANDER.BAS
X	RUN
X
X    Be sure not to run out of fuel!
X
X
XSelected notes from the author:
X
X    This is the DDS-BASIC Interpreter (Version 1.00). 
X
X    Immediate commands:
X
X	RUN	LIST	NEW	OLD filename
X	BYE	SAVE filename
X
X    Program commands:
X
X	variable names a to z		variables initialized to 0 on RUN
X	FOR var = exp TO exp		NEXT variable
X	GOSUB exp			RETURN
X	GOTO exp			IF exp THEN exp
X	INPUT variable			PRINT string
X	PRINT exp			var = exp
X	REM any text			END
X
X    Expressions (ranked by precedence):
X
X	Bracketed expressions
X	number (leading 0 for octal, 0x for hex, else decimal), variable
X	Unary -
X	* / 
X	+ - 
X	= <> 
X	> < 
X	<= >=
X	(* and + are also used for boolean AND and boolean OR)
X	Boolean expressions evaluate to 0 for false and 1 for true
X
X    Editing:
X
X	- Line editor using line re-entry.
X	- A line number with nothing following it, deletes the line.
X
X    Input format:
X
X	- Free format positioning of tokens on the line.
X	- No space is allowed before the line number.
X	- Exactly one space is needed between the OLD or SAVE command and 
X	  the filename.
X	- ALL INPUT MUST BE UPPERCASE.
X
X    Limits:
X
X	Line numbers		1-10000
X	Line length		999 characters
X	FOR nesting		26
X	GOSUB			999 levels
X	Program			Dynamically allocated
X	Expressions		-32768 - 32767 for 16 bit machines, 
X				-2147483648 - 2147483647 for 32 bit machines
X
X    Error checking / error reports:
X
X	No error checking is performed.
X	The message `core dumped' signifies a syntax or semantic error.
X
X    Hosting Environment:
X
X	ANSI C, traditional K&R C or OSF ANDF
X	ASCII or EBCIDIC character set
X	48K bytes memory
X
X    The Speed of DDS-BASIC Interpreter (Version 1.00). relative to
X    Microsoft Advanced BASIC 3.31 is Approximately 60%.
X
X    The code size could be further reduced by doing ugly things like
X    not declaring the return type of functions, not freeing memory,
X    #defining define, and joining lines.  In its present 1536 character
X    form the program is reasonably portable (it may fail to run in a
X    tagged object architecture) and nicely formatted (it fits in an
X    80*25 screen).
SHAR_EOF
$TOUCH -am 0922163990 1990/dds.hint &&
chmod 0444 1990/dds.hint ||
echo "restore of 1990/dds.hint failed"
set `wc -c 1990/dds.hint`;Wc_c=$1
if test "$Wc_c" != "2315"; then
	echo original size 2315, current size $Wc_c
fi
# ============= 1990/dg.hint ==============
echo "x - extracting 1990/dg.hint (Text)"
sed 's/^X//' << 'SHAR_EOF' > 1990/dg.hint &&
XBest Abuse of the C Preprocessor: <harvard!xait!pallio!dg> David Goodenough
X
X	David Goodenough
X	anonymous organization
X	541 Commonwealth Ave,
X	Newton, MA 02159
X	USA
X
XJudges' comments:
X
X    Compile and run.  Try:
X
X	echo "to C or not to C" | dg
X
X    Some C preprocessors get confused about single quotes in certain cases.
X    In particular, the following source line:
X
X   Cb12(ase(bco(acp(bi(acp(bcp(acp(bpl(aqu(bqu(A))))))))))))))))))))))))))))))
X
X    may need to be changed to:
X
X   Cb12(ase(bco(acp(bi(acp(bcp(acp(bpl('A'))))))))))))))))))))))))))))
X
X    if your C preprocessor botches single quotes in cpp expansions.
X
X    Systems that have index() and don't strchr() (e.g., BSD) should
X    compile with without -Dindex=strchr.
X
XSelected notes from the author:
X
X    If my preprocessor could hack it, I could write this as one single
X    line rather than 4, but when I do that I get a complaint "defines
X    nested too deeply".
X
X    Spoiler: (rot13 to read)
X
X    Guvf vf nabgure ebg13 wbo (oryvrir vg be abg) - gur #qrsvarf ner n
X    abiry jnl bs nqqvat gbxraf: '#qrsvar o12(k) 12 k' zrnaf gung ng
X    fbzr cbvag va gur fbhepr n 12 vf sbyybjrq ol gur pbzcerffrq arfgrq
X    qrsvarf. Gur o12 trgf gur cerivbhf pbzcerffvba nf na nethzrag, naq
X    cercraqf gur 12, guhf znxvat nabgure fgrc va gur erperngvba bs gur
X    fbhepr. Gur nkk() qrsvarf qb gur fnzr, ohg nqq gbxraf nsgre.
X
X    Nf sbe gur ebg13 nytbevguz, vg eryvrf ba vaqrk() gb svaq vs gur
X    punenpgre vf va gur frg N-Mn-m. y[] vf na neenl gung trgf svyyrq
X    jvgu:
X
X    "abcdefghijklmmmmnopqrstuvwxyzzzzABCDEFGHIJKLMMMMNOPQRSTUVWXYZZZZ"
X
X    Vs vaqrk() fnlf gur pune vf va gur nycunorg, gura kbe gur bssfrg
X    jvgu 16 gb genafyngr, naq bhgchg, bgurejvfr cnff vg hapunatrq.
SHAR_EOF
$TOUCH -am 0922165090 1990/dg.hint &&
chmod 0444 1990/dg.hint ||
echo "restore of 1990/dg.hint failed"
set `wc -c 1990/dg.hint`;Wc_c=$1
if test "$Wc_c" != "1733"; then
	echo original size 1733, current size $Wc_c
fi
echo "End of part 1, continue with part 2"
exit 0

-- 
For a good prime, call:  391581 * 2^216193 - 1



More information about the Alt.sources mailing list