Numbers that come in as strings

Predict the output · Basic · §9.1 Talking to your program

You run the code and type 12 for the first number and 30 for the second. Predict the two lines that print() prints. Leave out the prompt text that input() shows.

Code

a = input("First number: ")
b = input("Second number: ")
print(a + b)
print(int(a) + int(b))

Solve this problem in your browser

Python runs in your browser and checks your answer right away. Hints and the answer are on the problem page.