From 2072f264840a63ae4e8df29e6b6cb1bc394c06a3 Mon Sep 17 00:00:00 2001 From: El Yaagoubi Bilel <bilel.el-yaagoubi@student-cs.fr> Date: Wed, 12 Oct 2022 23:14:20 +0200 Subject: [PATCH] ok --- calculator/calculator.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/calculator/calculator.py b/calculator/calculator.py index ab4570f..58672ef 100644 --- a/calculator/calculator.py +++ b/calculator/calculator.py @@ -18,7 +18,7 @@ class Calculator: operators = STANDARD_OPERATORS self.operators = operators - def tokenize(self, line: str) -> list[Token]: + def tokenize(self, line: str): """ Tokenize an expression into a list of tokens. """ @@ -34,7 +34,7 @@ class Calculator: raise ValueError(f"Invalid token {token}") from exc return tokens - def parse(self, tokens: list[Token]) -> Expression: + def parse(self, tokens) -> Expression: """ Parse a list of tokens into an ordered expression. """ -- GitLab