I am getting None when i typed wrong input but when i typed correct input. It is not appear. kindly help me out with this concepts.
def order():
try:
count = int(input("How many order ? "))
return count
except Exception as e:
print("Kindly enter in numbers")
print("Example :- 1, 2, 3, 4, 5 etc..")
finally:
print("Thanks to choose our service.")
choice = order()
print(choice, " will be ordered soon!!")
Output:
How many order ? asdd
Kindly enter in numbers
Example :- 1, 2, 3, 4, 5 etc..
Thanks to choose our service.
None will be ordered soon!!