سلام دوستان
تکه کد زیر در کتاب a byte of python به عنوان تمرین آورده شده . اما نمی دونم چرا وقتی این کد رو می نویسم یا حتی copy/paste می کنم IDLE ارور می ده و اجراش نمی کنه .حالا اگه شما به این کد نگاهی بندازید و بگید مشکلش چیه ممنون می شم:
number = 23
guess = int(input('Enter an integer : '))
if guess == number:
print('Congratulations, you guessed it.') # New block starts here
print('(but you do not win any prizes!)') # New block ends here
elif guess < number:
print('No, it is a little higher than that') # Another block
# You can do whatever you want in a block ...
else:
print('No, it is a little lower than that')
# you must have guess > number to reach here
print('Done')
# This last statement is always executed, after the if statement is
executed