Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- let answers =[
- "Go for it!"
- "No way Jose!"
- "I'm not sure. Ask me again."
- "Fear of the unknown is what imprisons us."
- "It would be madness to do that!"
- "Only you can save mankind!"
- "Makes no difference to me, do or don't - whatever."
- "Yes, I think on balance that is the right choice"
- ]
- printfn "Welcome to Magic 8-Ball."
- printfn "Ask me for advice and then press enter to shake me"
- System.Console.ReadLine()
- for i = 1 to 4 do printfn "Shaking..."
- let rand = System.Random()
- let choice = rand.Next(answers.Length)
- printfn "%s" (answers.[choice])
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement