dimanche 28 février 2021

I can't figure out this while and if problem

When I input my number or anything else, it just skips the if statement and goes to the else. I can't figure out what's wrong; I've tried every way to change it. Still a total noob here.

arv = input("Sisestage arv: ")
    arv1 = 0
    kordus = 1
    
    
    while kordus <= 10:
        arv = input("Sisestage arv: ")
        if arv == arv.isnumeric():
             arv1 + arv
             print (arv1)
             kordus += 1
        else:
            print (arv)
            break

Aucun commentaire:

Enregistrer un commentaire