Den fredag 14 oktober 2016 kl. 20:30:20 UTC+2 skrev MRAB: > On 2016-10-14 19:11, LongHairLuke wrote: > > Hi, l l am trying to make a simple guess program. This is my script: > > > > def main(): > > print ("Guess a letter between a and e") > > randomNumber = b > > > > userGuess = input("Your guess: ") > > > > if userGuess == randomNumber: > > print("You got it") > > else: > > print ("That's not it") > > > > main() > > > > > > When l run the program l get error: userGuess is not defined, but l defined > > userGuess at line 5. I don't get it someone plese help :) > > > Lines 7 to 10 should be indented like the preceding lines. The way > you've written them, they're outside 'main'.
indented? can you explain :) -- https://mail.python.org/mailman/listinfo/python-list