From d42f07736cc51eba6f3bf514f93dc765a791698a Mon Sep 17 00:00:00 2001 From: Alexandre Faure <alexandre.faure@student-cs.fr> Date: Thu, 13 Oct 2022 18:26:44 +0200 Subject: [PATCH] Update operators.py --- calculator/operators.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/calculator/operators.py b/calculator/operators.py index 8da0d85..71135dd 100644 --- a/calculator/operators.py +++ b/calculator/operators.py @@ -1,6 +1,8 @@ """ Operator module contains the Operator class and a list of standard operators. """ + + class Operator: """ Operator class is a binary operator with a symbol, a precedence and an evaluation function. @@ -21,6 +23,6 @@ class Operator: STANDARD_OPERATORS = { '+': Operator('+', 1, lambda a, b: a + b), '-': Operator('-', 1, lambda a, b: a - b), - '*': Operator('×', 2, lambda a, b: a * b), + '*': Operator('*', 2, lambda a, b: a * b), '/': Operator('/', 2, lambda a, b: a / b), } -- GitLab