diff --git a/calculator.py b/calculator.py index 607c2c2..bb224b7 100644 --- a/calculator.py +++ b/calculator.py @@ -1,9 +1,17 @@ -class Calculator: - def add(self, x, y): - return x + y +class Calculator: + def add(self, x, y): + return x + y + + def subtract(self, x, y): + return x - y -if __name__ == "__main__": - calc = Calculator() - print("Welcome to Calculator!") - print("Current feature: Addition") - print("Example: 5 + 3 =", calc.add(5, 3)) \ No newline at end of file + def multiply(self, x, y): + return x * y + +if __name__ == "__main__": + calc = Calculator() + print("Welcome to Calculator!") + print("Current features: Addition, Subtraction, Multiplication") + print("Example: 5 + 3 =", calc.add(5, 3)) + print("Example: 5 - 3 =", calc.subtract(5, 3)) + print("Example: 5 * 3 =", calc.multiply(5, 3)) \ No newline at end of file