This commit is contained in:
Maxwell Jeffress
2026-02-20 11:42:22 +11:00
commit 3fdb90a652
5 changed files with 189 additions and 0 deletions

30
old/activity-core.py Normal file
View File

@@ -0,0 +1,30 @@
# Created by Maxwell Jeffress, 11/02/2026
# Does add, subtract, multiply, and divide operations on 2 numbers.
left = 0
right = 0
# GET left (user input)
try:
left = int(input("Left side: "))
except ValueError:
print("Invalid input!")
exit(1)
# GET right (user input)
try:
right = int(input("Right side: "))
except ValueError:
print("Invalid input")
exit(1)
add = left + right
sub = left - right
mul = left * right
div = left / right
print("left + right =", add)
print("left - right =", sub)
print("left * right =", mul)
print("left / right =", div)