Compare commits

..
2 Commits
Author SHA1 Message Date
chris 6aa5a2b6b3 Add tests and code for divide function 2026-06-02 16:18:32 -04:00
chris 4ba1e2cb90 Add multiply function 2026-06-02 15:00:56 -04:00
2 changed files with 11 additions and 0 deletions

No files matched your search

+8
View File
@@ -9,3 +9,11 @@ def add(first_term, second_term):
def subtract(first_term, second_term): def subtract(first_term, second_term):
return first_term - second_term return first_term - second_term
def multiply(first_term, second_term):
return first_term * second_term
def divide(first_term, second_term):
return first_term / second_term
+3
View File
@@ -15,3 +15,6 @@ class TestCalculator:
def test_multiplication(self): def test_multiplication(self):
assert 100 == calculator.multiply(10, 10) assert 100 == calculator.multiply(10, 10)
def test_divide(self):
assert 20 == calculator.divide(100, 5)