2020-10-29 at 10:32 PM UTC
The following users say it would be alright if the author of this
post didn't die in a fire!
2020-10-29 at 10:44 PM UTC
Take 73,502 muffins, subtract 71,555 + your age, and youll be in the ballpark of the year you were born then just add or subtract whatever number you need to to get to the year you were born, and you'll have the year you were born.
2020-10-29 at 10:45 PM UTC
it says my age is "syntax error"
2020-10-29 at 10:49 PM UTC
the calculator app I downloaded was just a virus..
Back to the python compiler for me
programming looks like flirting with girls on myspace in 2005
2020-10-30 at 12:28 AM UTC
i have finished my python calculator script. Compiling now and doing the maths to figure this out
# idk wat im doering
# add
def add(x, y):
return x + y
# Take away
def subtract(x, y):
return x - y
print("do maths.")
print("1.Add a numbers")
print("2.Minus a numbers")
while True:
# choose mode
choice = input("type 1 to add type 2 to subtract: ")
# i found this part on google
if choice in ('1', '2'):
num1 = float(input("Enter first number: "))
num2 = float(input("Enter second number: "))
if choice == '1':
print(num1, "+", num2, "=", add(num1, num2))
elif choice == '2':
print(num1, "-", num2, "=", subtract(num1, num2))
break
else:
print("u pressed wrong button")
The following users say it would be alright if the author of this
post didn't die in a fire!
2020-10-30 at 12:33 AM UTC
-SpectraL
coward
[the spuriously bluish-lilac bushman]
80 - (2020 - age) + 40 = birthyear
2020-10-30 at 12:40 AM UTC
Originally posted by Ghost
i have finished my python calculator script. Compiling now and doing the maths to figure this out
# idk wat im doering
# add
def add(x, y):
return x + y
# Take away
def subtract(x, y):
return x - y
print("do maths.")
print("1.Add a numbers")
print("2.Minus a numbers")
while True:
# choose mode
choice = input("type 1 to add type 2 to subtract: ")
# i found this part on google
if choice in ('1', '2'):
num1 = float(input("Enter first number: "))
num2 = float(input("Enter second number: "))
if choice == '1':
print(num1, "+", num2, "=", add(num1, num2))
elif choice == '2':
print(num1, "-", num2, "=", subtract(num1, num2))
break
else:
print("u pressed wrong button")
Some tips
1. I got rid of the add and subtract functions, you can just do it inline
2. prefer variable names like x and y to num1 and num2. It's easy to get the latter confused.
3. you can use string interpolation to make printing strings with variables a bit nicer
# idk wat im doering
# add
print("do maths.")
print("1.Add a numbers")
print("2.Minus a numbers")
while True:
# choose mode
choice = input("type 1 to add type 2 to subtract: ")
# i found this part on google
if choice in ('1', '2'):
x = float(input("Enter first number: "))
y = float(input("Enter second number: "))
if choice == '1':
print(f`x + y = {x + y}`)
elif choice == '2':
print(f`x - y = {x - y}`)
break
else:
print("u pressed wrong button")
The following users say it would be alright if the author of this
post didn't die in a fire!
2020-10-30 at 1:08 AM UTC
-SpectraL
coward
[the spuriously bluish-lilac bushman]
disclaimer: this equation doesn't not compute using American beer or Americans
2020-10-30 at 6:41 AM UTC
This is one of those memes that goes in waves. Just saw it on facebook. Remember seeing it a few years back.