Answer the question
In order to leave comments, you need to log in
How to determine the right numbers without error?
elif int(message.text) <= 14:
elif int(message.text) <= 14:
ValueError: invalid literal for int() with base 10: 'выфв'
Answer the question
In order to leave comments, you need to log in
Use string method isdigit()
https://pythonz.net/references/named/str.isdigit/
if message.text.isdigit():
if int(message.text) <= 14:
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question