Answer the question
In order to leave comments, you need to log in
Why does the message local variable 'balanc' referenced before assignment come out?
I am writing a telegram bot and pytelegrambotapi
Here is a line of code:
elif call.data == 'four':
if balanc >= 10:
balanc = balanc - 10
bot.answer_callback_query(call.id, "Ты купил кролика")
elif balanc < 10:
bot.answer_callback_query(call.id, "У вас недостаточно денег!")
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question