Input From the User

This lesson will focus on Python's built-in input function.

We'll cover the following

The input() function

In Python, input() function is used to take input from user.

The input is automatically converted to string. If you enter a number, it will also be converted to a string.

Example

Below is an executable asking for user’s name as an input.

Before pressing the ‘Run’ button, add your name in the text field below the widget.

Get hands-on with 1200+ tech skills courses.