Advertisement
Guest User

Untitled

a guest
Dec 8th, 2019
117
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.82 KB | None | 0 0
  1. print("Welcome to your first Python quiz!")
  2. print("...")
  3. yes_or_not = input("Are you ready to test what you've learned? >> ")
  4.  
  5. if yes_or_not == "Yes" or yes_or_not == "Yeah" or yes_or_not == "Definitely":
  6. print("OK, then! Let's start the quiz")
  7. print("...")
  8. q1 = input("Is Python the easiest programming language to start learning how to code? >> ")
  9. if q1 == "Yes":
  10. print("Correct!")
  11.  
  12. else:
  13. print("Sorry, buddy. Wrong answer!")
  14.  
  15. q2 = input("Is identation relevant when coding? >> ")
  16. if q2 == "Yes":
  17. print("Correct!")
  18.  
  19. else:
  20. print("Sorry, buddy. Wrong answer!")
  21.  
  22. elif yes_or_not == "No" or yes_or_not == "Nope":
  23. print("Don't worry. You can take the quiz later.")
  24.  
  25.  
  26. else:
  27. print("I don't understand what you're saying, buddy.")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement