Text Size
Text Size
Exit Full Screen
Python Mini
Show
Source Code
View Source Code in Full Screen
Open in New Tab
#trivia quiz badge import time time.sleep (1) print "Welcome to my trivia game" print "" time.sleep (1) what1=input ("what color light is on the bottom of a street light").lower() if what1 == "green": print "Correct!" else: print "Wrong! The correct answer was green" #if what1 == "green" or " Green": what2=input ("who was the second president of the United States?") if what2 == "John Adams": print "Correct!" else: print "Wrong! The correct answer was John Adams" what3=input ("What book did Thomas Paine make?") if what3 == "Common Sense": print "Correct!" else: print "Wrong! The correct answer was Common Sense"
Trivia.py
( around 22 lines python code )
Published By:
PlaneBagel
Published on
2023-01-09T17:20:25Z
Python Mini
- an
OYOclass
application,
own your own class today
.
Run
Result
×
Error message shows here