mercredi 2 septembre 2020

Why is my if statement not working and giving appropriate answer? [closed]

Why if statement not working? I am trying to get good answer.

age = input("your number")
customer = {0: "zero",
            1: "one",
            2: "two", 3: "three", 4: "four", 5: "five"
            }
x = [0, 1, 2]
y = [0, 1, 2, 3, 4, 5]
for s in x:
    for w in y:
        b=age[s]
        if b == w:
            print(f"number is{customer[w]}")

Aucun commentaire:

Enregistrer un commentaire