I am a Python NOOB and I have a Python function game()
that executes perfectly, when the game ends I ask the player to play again. The input
and if
statement works (it prints my corny comment) but the next invocation of game()
doesn't execute and the program ends? Why?
# Lots of cool game() code above here ^^^
game() #first invocation of the game() function, works great...
print ("Play Again? Y=YES, Any other key to quit")
if input() == "y" or "Y":
print("oh yeah, its on!!!!")
game()
else:
exit