while price < 0 or price > 100:
    if ttt >= 2:
        print('This is an invalid entry, Please enter a number between 0 and 100')
price = input('Please enter your marks for Maths:')
ttt = ttt + 1
Циклы в Python