#print "hello" #Print "MASH" #Choose the story category #Choose the number of options for each category #Choose a random number #Eliminate category options when you reach the magic number #Circle the final option in each category #Use the final options to tell your MASH story categories = {"transportation":["mercedes", "horse", "limo", "Honda"], "location":["Miami", "California", "Rome", "Paris"], "job":["construction worker", "teacher", "Doctor", "lawyer"], "children":[5,0,3,2], "pets":["dog", "cat", "hamster", "fish"], "future husband":["Channing Tatum", "Harry Styles", "Nobody", "Kevin"]} print "Let's Play MASH! " print "Choose a random number and your fate will be decided!!!" random = input("the magic number you chose is: ") print random
Run
Reset
Share
Import
Link
Embed
Language▼
English
中文
Python Fiddle
Python Cloud IDE
Follow @python_fiddle
Browser Version Not Supported
Due to Python Fiddle's reliance on advanced JavaScript techniques, older browsers might have problems running it correctly. Please download the latest version of your favourite browser.
Chrome 10+
Firefox 4+
Safari 5+
IE 10+
Let me try anyway!
url:
Go
Python Snippet
Stackoverflow Question