0

I have a problem with this code.

First = input("First: ") Second = input("Second: ") sum = int(First) + int(Second) print("sum " + str(sum)) I want to make a simple addition code where I can input 2 numbers and get a sum.

20th Jan 2025, 12:38 PM
SAWDAH SALIM
SAWDAH SALIM - avatar
4 ответов
+ 2
SAWDAH SALIM The code is working properly, what problem are you facing?
20th Jan 2025, 12:45 PM
Gulshan Mahawar
Gulshan Mahawar - avatar
+ 1
Keep in mind that Sololearn's compiler doesn't accept real-time input. You have to enter your information all at once on separate lines, like this: 5 6
20th Jan 2025, 3:02 PM
Ausgrindtube
Ausgrindtube - avatar
0
My code comes out like this First: Second: sum (your answer)
20th Jan 2025, 6:20 PM
SAWDAH SALIM
SAWDAH SALIM - avatar
0
And the coding inspo I was using didn't have it.
20th Jan 2025, 6:20 PM
SAWDAH SALIM
SAWDAH SALIM - avatar