Print Multiple Variables in Python

Print Multiple Variables in Python. A Python program to print the single value into multiple variables. Using this program we can print the single value into multiple variables. Different variable names are provided to the left of the assignment operator, separated by a comma, when assigning multiple variables in a single line. The same is true for their values, except that they should be placed to the right of the assignment operator.

x = y = "inlarn.com"
print(x)
print(y)

 

Output:

inlarn.com

inlarn.com

Variable in Python

A Python variable is a memory area designated for storing values. A variable in a Python program, in other words, provides data to the computer for processing. In Python, every value has a datatype. Numbers, Lists, Tuples, Strings, dictionaries, and more data types are available in Python. A Python variable is a memory area designated for storing values. A variable in a Python program, in other words, provides data to the computer for processing.

Print Statement in Python Program

The print() method outputs the message supplied to the screen or another standard output device. The message can be a string or any other object; the object will be converted to a string before being displayed on the screen. The print statement is used to deliver output to your computer system’s standard output unit (typically your monitor, but sometimes your printer). The print statement instructs the computer to output anything, either to the terminal or to the printer. It may be utilized in a variety of ways. Printing the value of a single variable is one method.