I tried to indent lots of time but now i can't , really need a help pls!!!!! if i indent everything it says the else in line 32 has invalid syntax if i move it says indentation lol..pls help!
"""im building a program that rolls a pair of dice and asks the user to guess a number. Based on the user's guess, the program should determine a winner. If the user's guess is greater than the total value of the dice roll, they win! Otherwise, the computer wins.""" from random import randint from time import sleep def get_user_guess(): user_guess = int(raw_input("Guess a number: ")) return user_guess def roll_dice(number_of_sides): first_roll = randint(1,number_of_sides) second_roll = randint(1,nunber_of_sides) max_val = number_of_sides * 2 print "The maximum possible value is: " + str(max_val) sleep(1) user_guess = get_user_guess() if user_guess > max_val: print "No Guessing higher than the maximum possible value!" return else: print "Rolling..." sleep(2) print "the first value is %d" % first_roll sleep(1) print "the first value is %d" % second_roll sleep(1) total_roll=first_roll+second_roll print "the total roll is %d" % total_roll print "result..." sleep(1) if user_guess > total_roll: print "You won Congrats" return else: print "you lost, try again." return roll_dice(6)