B
blackneos940
Guest
It just doesn't seem to add up..... ... ... ... Heh.... :3 Anyway..... I run it, and it says this:
Traceback (most recent call last):
File "C:\Users\Adam\Documents\Testing_Grounds\Examples_of_Python\Smashing_Atoms\My_Programs\Serious_Stuff\Actual_Calculator.py", line 29, in <module>
print (number / number_2)
TypeError: unsupported operand type(s) for /: 'str' and 'str'
This happens when I try to do everything but Add.... And even THAT doesn't work like I THINK it should..... :< It just takes your numbers and pieces them together....... 3 and 8 do NOT equal 38..... :< What happened.....? Will I always be this way......? Oh yeah..... Here's the Code, before I forget.....
..... Thanks for any help guys....
Traceback (most recent call last):
File "C:\Users\Adam\Documents\Testing_Grounds\Examples_of_Python\Smashing_Atoms\My_Programs\Serious_Stuff\Actual_Calculator.py", line 29, in <module>
print (number / number_2)
TypeError: unsupported operand type(s) for /: 'str' and 'str'
This happens when I try to do everything but Add.... And even THAT doesn't work like I THINK it should..... :< It just takes your numbers and pieces them together....... 3 and 8 do NOT equal 38..... :< What happened.....? Will I always be this way......? Oh yeah..... Here's the Code, before I forget.....
Code:
print ("My next attempt at a good Calculator in Python!!\n")
print ("Enter a number now!\n")
number = input()
print ("Enter the Math Operator to Calculate the numbers! (+, -, *, or /)\n")
math_symbol = input("")
print ("Enter a second number!\n")
number_2 = input()
if math_symbol == "+":
print (number + number_2)
elif math_symbol == "-":
print (number - number_2)
elif math_symbol == "*":
print (number * number_2)
elif math_symbol == "/":
print (number / number_2)
else:
print ("Error: Please input one of the four Math Operators!")
..... Thanks for any help guys....