Last active
August 29, 2018 21:11
-
-
Save topherPedersen/0052cc1a037b3473b7bd7d01bc0225d3 to your computer and use it in GitHub Desktop.
Super Simple Magic 8 Ball
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Super Simple Magic 8 Ball | |
| # https://bit.ly/2LGEDnh | |
| # Greet User | |
| print("Welcome to Magic 8 Ball!") | |
| # Prompt User to Ask a Question | |
| question = raw_input("What is your question?") | |
| # Generate Random Number | |
| import random | |
| randomNumber = random.randint(0, 1) | |
| # Answer Users Question | |
| if randomNumber == 1: | |
| print("Yes, definitely.") | |
| else: | |
| print("Very doubtful.") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment