+ 1

I wrote a simple code.

x=float (input ("enter a number:")) print (x) y=float (input ("enter another number:")) print (y) sum=(x+y) print (sum) here i enter 7 and 8 and the output is- 1. enter a number: 7.0 2. enter another number: 8.0 3. 15.0 here suppose in the third line i want something like- the sum is 15.0 how do i go about doing this. that is adding the word "the sum is 15.0" in the third line of the output. help

19th Apr 2017, 11:17 AM
stephen haokip
stephen haokip - avatar
2 Respuestas
+ 11
print ("the sum is:", sum)
19th Apr 2017, 11:41 AM
J.G.
J.G. - avatar
+ 1
Nice. Programming looks so confusing at first, but once you've got that logical mindset, it all makes perfect sense.
21st Apr 2017, 10:20 AM
Niall Matthews
Niall Matthews - avatar