Python input() Function Presentation


This is the presentation associated with the Python input() function video.

Download Presentation

Python input() Function Video Question

This is the Question that was asked in the python input() function video

Question : Write a program to input two number and display the sum in output. This task has to be achieved in a single line.
Hint: You can use the int() for typecasting.
In [1]:
print("Sum:", int(input("Please enter first number:")) + int(input("Please enter second number:")))
Please enter first number:4
Please enter second number:3
Sum: 7