--Originally published at Sierra's Blog
Input:
Input is the way you can make Python ask you something it’s how the program interacts with the user.
Input is used to accept the data from the user.
How does it work?
Variable + = + input + (“text” )
- input() – The code that forces Python to accept the data from the user
- Variable – The name you’re assigning to the input.
- (“text”) – The text that will make the user understands what you’re asking for.
Examples:
And the outcome is:
Output:
output is to send a emission, from python to the user, the basic way is using the print statement.