Input and Output
I LOVE DOING THIS :)
In Python 2, you have a built-in function raw_input()
, whereas in Python 3, you have input()
. The program will resume once the user presses the ENTER key.
Output using print()
function
print()
functionMore on using print()
print()
By default, print
goes to a new line at the end. You can change this by using the keyword end
You can change this default implementation. You can have a colon :
between the letters instead of a new line
Walrus Operator :=
:=
This Operator allows you to assign values to variables within an expression
Importing Sys for User Inputs
The sys module provides various functions and variables. It allows operating on the interpreter as it provides access to the variables and functions that interact strongly with the interpreter
Last updated