I am starting to code a game just to practice. However, the user needs to enter an odd number to play. If they don't then I want the program to ask them for an odd number they loop and play again. I put this code in the else statement but if I enter an odd number it will not loop again.
Question 2: how can I get the program to display Game 1, Game 2, etc as the loop runs however many times the input in 'Games' is?
Can someone help?
games = input("How many games would you like to play?")
for i in range(games):
if games % 2 == 1:
print('Game 1')
# code here
else:
input('Enter an odd number')