diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..7a60b85 --- /dev/null +++ b/.gitignore @@ -0,0 +1,2 @@ +__pycache__/ +*.pyc diff --git a/src/__pycache__/calculator.cpython-315.pyc b/src/__pycache__/calculator.cpython-315.pyc deleted file mode 100644 index 188bff0..0000000 Binary files a/src/__pycache__/calculator.cpython-315.pyc and /dev/null differ diff --git a/src/calculator.py b/src/calculator.py index 983e401..b6e95e6 100644 --- a/src/calculator.py +++ b/src/calculator.py @@ -8,11 +8,7 @@ def subtract(left: int, right: int) -> int: return left - right -def multiply(left: int, right: int) -> int: - return left * right - - -def divide(left: int, right: int) -> int: +def modulo(left: int, right: int) -> int: if right == 0: - raise ValueError('division by zero') - return left // right + raise ValueError('modulo by zero') + return left % right