Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- score=0
- print ("Welcome to Trivial Trivia")
- print ("Answer three questions about simple machines and earn a trivia badge.")
- print ("Question Number 1")
- q1=input("What kind of simple machine is a seesaw? ")
- if q1=="lever" or q1=="Lever":
- print("You are correct. The answer is "+q1+".")
- score=score+1
- else:
- print("I am sorry. The answer is not "+q1+".")
- intscore=str(score)
- print("Your current score is "+intscore+".")
- q2=input("What kind of simple machine is an ax? ")
- if q2=="wedge" or q2=="Wedge":
- print("You are correct. The answer is "+q2+".")
- score=score+1
- else:
- print("I am sorry. The answer is not "+q2+".")
- intscore=str(score)
- print("Your current score is "+intscore+".")
- q3=input("What kind of simple machine is a window shade? ")
- if q3=="pulley" or q3=="Pulley":
- print("You are correct. The answer is "+q3+".")
- score=score+1
- else:
- print("I am sorry. The answer is not "+q3+".")
- intscore=str(score)
- print("Your current score is "+intscore+".")
- if score==0:
- print("Your score is "+intscore+" I am sorry you did not receive a badge. Please try again.")
- elif score==1:
- print("Your score is "+intscore+" You are awarded the Trivia Novice Badge.")
- elif score==2:
- print("Your score is "+intscore+" You are awarded the Trivia Proficiency Badge.")
- else:
- print("Your score is "+intscore+" You are awarded the Trivia Expert Badge.")
- print ("Thank you for playing Trivial Trivia!")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement