+ 2

How to use 5+4 in python

17th Jan 2017, 5:36 PM
Tanish Mahajan
Tanish Mahajan - avatar
11 Answers
+ 16
Consol: >>>5+4 ENTER
20th Jan 2017, 4:54 AM
Sergey
+ 3
print(5+4) Idk needs more explaining
17th Jan 2017, 11:42 PM
Jared
Jared - avatar
+ 3
a=5 b=4 print(a+b)
23rd Jan 2017, 4:09 PM
FAGO LION
FAGO LION - avatar
+ 3
Sherlock your program won't work because you can't use the + with an integer
25th Jan 2017, 2:21 PM
ramzi
ramzi - avatar
+ 2
print(5+4)
18th Jan 2017, 4:10 PM
ramzi
ramzi - avatar
+ 2
print("5+4=" + str(5+4)) (fix for Sherlock's code, as ramzi says you can't add a string and an integer without converting one first) I'm still not sure what the problem Tanish is having but at least this code displays an equation for 5+4
26th Jan 2017, 2:55 PM
Phil
Phil - avatar
+ 1
Could you explain a little more? I don't quite see the issue.
17th Jan 2017, 6:50 PM
Nick Ferguson
Nick Ferguson - avatar
+ 1
print(5+4)
25th Jan 2017, 2:13 PM
Oussama Draid
Oussama Draid - avatar
0
print("5+4="+(5+4))
21st Jan 2017, 1:19 AM
Sherlock
Sherlock - avatar
0
print( 5+4)
31st Jan 2017, 2:34 PM
Subagio Bawor
Subagio Bawor - avatar
0
print (5+4)
4th Feb 2017, 12:16 PM
FLATRON
FLATRON - avatar