D
D
Danya Ududyak2019-07-20 15:15:22
Python
Danya Ududyak, 2019-07-20 15:15:22

How to prohibit the input of several operations and points in a row?

Hello!
I am writing a graphing calculator in python using Kivy.
My task at the moment is to prohibit the input of several operations or points in a row.
I somehow got to similar information, but it was explained simply to raise the flag when an operation or point is entered, and after the introduction of the operand, lower it. I'm a newbie so I don't understand what this means, please help!

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
alternativshik, 2019-07-20
@alternativshik

enter a variable, for example has_dot = False
When pressing a dot, if not has_dot, set has_dot = True, draw a dot, otherwise, ignore the pressing.
Same with operators.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question