I'm writing a code for a dice roll game and getting a weird syntax error. The syntax error I get for the script below is: invalid syntax: else: ^
import random num = random.randint(1, 7) def dice_roll(): gold = 0 input = ('Do you want to play again?' ) if num == 2: gold = (gold + 2) print (gold) print ('You Win!') print (input) if input != ('yes'): dice_roll() else: print ('Loser') dice_roll() Does someone know why this code would give me such an error?