Little Game

Discuss software for the Apple 1/replica 1

Little Game

Postby Toolkitman » Oct Tue 26, 2010 9:40 am

I'm just learining BASIC, and i have made a very little game where you have to find the number of the computer. Changing the RND number you change the probability.
Code: Select all
10 DIM F$(3)
20 INPUT "SHALL WE PLAY A GAME",F$
30 IF F$= "YES" THEN 60
40 PRINT "OK BYE BYE"
50 END
60 INPUT "YOUR NUMBER",A
70 B=RND(10000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000)
80 TAB 15 :PRINT "YOUR NUMBER IS:",A
90 TAB 15 : PRINT "COMPUTER NUMBER IS:",B
100 IF A=B THEN PRINT "YOU WIN!!!!!"
110 IF A<>B THEN PRINT "YOU LOSE"
120 END


Enjoy! :mrgreen:
User avatar
Toolkitman
 
Posts: 83
Joined: Jul Mon 12, 2010 3:01 pm
Location: Venice,Italy

Return to Software

Who is online

Users browsing this forum: No registered users and 1 guest

cron