Welcome back.
Now let's move to the next lesson which is getting input from the user.
We use the input function to ask the user for information for example username.
This is the variable equals to input function.
What is your name.
Let me run.
And here we get an input box and waiting for the input from the user.
Let me name it as John.
Hit enter.
The second line will be executed.
Hello John, welcome to Python.
Here we are using the formatted string and we're going and we used the username variable.
We get the value from the user from the input from the user and place it in our hello statement.
So again hello we get the username value from the user.
And we continue with Welcome to Python.
The input function always returns a string to use numbers, convert them for example.
Birth year.
Input.
Enter your birth year.
For example.
Uh one 1992.
Enter.
You are 33 years old.
This returns a string.
Age equals to 2025 minus int.
I'm converting this string into integer using this int function.
This int function converts a number or string to an integer or return zero if no arguments are given.
Okay, so this returns transform and convert the birth year, which is a string into integer.
Because we need to to, uh, make this subtraction from an integer.
Also, we used the formatted string and we replaced the age with its actual value.
Okay guys.
So this is how we use the input and get the input from the user.