File HILO.BA (BASIC source file)

Directory of image this file is from
This file as a plain text file

90 RANDOMIZE
100 PRINT "THIS IS THE GAME OF HI-LO"\PRINT
110 PRINT "YOU WILL HAVE 6 TRIES TO GUESS THE AMOUNT OF MONEY IN THE"
120 PRINT "HI-LO JACKPOT, WHICH IS BETWEEN 1AND 100 DOLLARS.  IF YOU"
130 PRINT "GUESS THE AMOUNT, YOU WIN ALL THE MONEY IN THE JACKPOT!"
140 PRINT "THEN YOU GET ANOTHER CHANCE TO WIN MORE MONEY.  HOWEVER,"
150 PRINT "IF YOU DO NOT GUESS THE AMOUNT, THE GAME ENDS."\PRINT
160 R=0
170 B=0\PRINT
180 Y=INT(100*RND(0))
200 PRINT "YOUR GUESS";
210 INPUT A
220 B=B+1
230 IF A=Y THEN 300
240 IF A>Y THEN 270
250 PRINT "YOUR GUESS IS TOO LOW"\GOTO 280
270 PRINT "YOUR GUESS IS TOO HIGH"
280 PRINT\IF B<6 THEN 200
290 PRINT "YOU BLEW IT....TOO BAD....THE NUMBER WAS";Y\R=0\GOTO 350
300 PRINT "GOT IT!!!!!!!!   YOU WIN";Y;"DOLLARS."
310 R=R+Y
320 PRINT "YOUR TOTAL WINNINGS ARE NOW";R;"DOLLARS."
350 PRINT\PRINT "PLAY AGAIN (YES OR NO)";
360 INPUT A$\IF A$="YES" THEN 170
380 PRINT\PRINT "SO LONG.  HOPE YOU ENJOYED YOURSELF!!"
390 END



Feel free to contact me, David Gesswein djg@pdp8online.com with any questions, comments on the web site, or if you have related equipment, documentation, software etc. you are willing to part with.  I am interested in anything PDP-8 related, computers, peripherals used with them, DEC or third party, or documentation. 

PDP-8 Home Page   PDP-8 Site Map   PDP-8 Site Search