Different Styles Of Print Statements In Python Programming

What is a Print Statement?

Print statement is used to send the output to the computer screen. The message can be string or any other objects.

Syntax

print (objects, sep = ‘seperator’, end = ‘end’, file = file, flush = flush)

Arguments                                             Description

objectsAny objects as many as you likeseperatorHow to separate objects (Optional)endWhat to print at the end (Optional)fileAn object with a write method (Optional)flushA Boolean value , By default it is False (Optional)

HOW TO PRINT A STRING?

To print the string, we have to use the print () Function and inside the double quotes (“”) just enter the string you want to print

OUTPUT

We can also perform arithmetic operations inside the print () function. Let’s see an example of addition of two numbers

#technology #python #python programming

Different Styles Of Print Statements In Python Programming
1.30 GEEK