Python input() print() function

by Atakan

Today, I will talk about 2 features that we will use the most basic. These 2 features are the functions that will interact with the user the most. There is a similar structure in other programming languages. In my other examples, we often used the print function. You more or less understood the logic.

The input () function allows us to read the keys pressed from the keyboard and assign them to a variable. The return format is in string format.

Parameter information message can be written to the parameter.
for example:

answer = input("How are you ?")
print("answered ",answer)

Result

As is known, the print method is used to display the value that comes as a parameter.
for example:

print("param1","param2","param3","param4")  #param1 param2 param3 param4
print("param1","param2","param3","param4",sep=".")  #param1.param2.param3.param4
print("param1","param2","param3","param4",sep=",")  #param1,param2,param3,param4

You may also like

This website uses cookies to improve your experience. We'll assume you're ok with this, but you can opt-out if you wish. OK Read More