RosettaCodeData/Task/Magic-8-ball/Commodore-BASIC/magic-8-ball.basic

23 lines
899 B
Plaintext
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

10 dim f$(19):for i=0 to 19:read f$(i):next
20 print chr$(147);chr$(14)
30 print "Press any key to reveal your fortune."
40 print:print "Press Q to quit.":print
50 fo=int(rnd(1)*20):get k$:if k$="" then 50
60 if k$="q" then print "Good luck!":end
70 print "Your fortune reads:"
80 print spc(5);f$(fo):print
90 print "Again? (Y/N)"
100 get k$:if k$="" then 100
110 if k$="y" then goto 20
120 end
1000 data "It is certain.","It is decidedly so."
1010 data "Without a doubt.","Yes definitely."
1020 data "You may rely on it.","As I see it, yes."
1030 data "Most likely.","Outlook good.","Yes."
1040 data "Signs point to yes.","Reply hazy, try again."
1050 data "Ask again later.","Better not tell you now."
1060 data "Cannot predict now.","Concentrate and ask again."
1070 data "Don't count on it.","My reply is no."
1080 data "My sources say no.","Outlook not so good."
1090 data "Very doubtful."