while True:
    try:
       num = int(input("enter a num :"))
       break

    except ValueError:
        print("u didnt enter a num")
    except:
        print("an unknown error occured")
print("thank u")
print(num)

e62322bf7555bf89c0a9da02352321d6c33c38e4
<mask token>

while True:
    try:
        num = int(input('enter a num :'))
        break
    except ValueError:
        print('u didnt enter a num')
    except:
        print('an unknown error occured')
print('thank u')
print(num)

while True:
    try:
       num = int(input("enter a num :"))
       break

    except ValueError:
        print("u didnt enter a num")
    except:
        print("an unknown error occured")
print("thank u")
print(num)
