diff --git a/main.py b/main.py index 376d083..14d7902 100755 --- a/main.py +++ b/main.py @@ -85,17 +85,17 @@ def calcul(left: int, right: int, res: int, operation='+'): if operation in ['+', 'add', 'sum']: result = left + right - if operation in ['-', 'sub']: + elif operation in ['-', 'sub']: result = left - right - if operation in ['*', 'mul', 'prod']: + elif operation in ['*', 'mul', 'prod']: result = left * right - if operation in ['/', 'div']: + elif operation in ['/', 'div']: result = left / right - if operation in ['&', 'and']: + elif operation in ['&', 'and']: result = left & right - if operation in ['|', 'or']: + elif operation in ['|', 'or']: result = left | right - if operation in ['^', 'xor']: + elif operation in ['^', 'xor']: result = left ^ right else: result = left % right