Print Hello World in Python Practice Program #3

Share with others

Print Hello World in Python

This Program “Print Hello World in Python” is a very basic program. It is basically used to demonstrate the print() function of Python. This program shows that how can we print a string in Python.

What is print() function in Python?

print() function is an inbuilt function in python. This function is used to display/print a message (string) on the screen.

Syntax of print() function

print(value(s), sep=separator, end='\n')

Parameters of print() function

  1. value(s) : Any number of values or objects. All values will be converted into string before printing.
  2. sep = ‘separator’ : This is an optional parameter. It specifies how to separate more than one string.
  3. end = “\n” : It is also an optional parameter. This parameter is used to print at the end of the string.

Program to print “Hello World” in Python.

print hello world in python
print hello world in python

Output of Program

print hello world in python output
hello world in python – Output

More Examples of print() function

print hello world in python examples

OUTPUT of above print statements

Explanation of above print statements

  1. First print statement is printing two strings separated by comma(,)
  2. Second print statement is showing the use of ‘sep’ parameter of print() function.
  3. Third print statement is showing the use of ‘\n’. It is used to bring the string(after the ‘\n’) in the next line.
  4. Fourth statement is showing the use of ‘end’ parameter of print() function.



MCQ of Computer Science Chapter Wise

1. Functions in Python

2. Flow of Control (Loop and Conditional statement)

3. 140+ MCQ on Introduction to Python

4. 120 MCQ on String in Python

5. 100+ MCQ on List in Python

6. 50+ MCQ on Tuple in Python

7. 100+ MCQ on Flow of Control in Python

8. 60+ MCQ on Dictionary in Python


Important Links

100 Practice Questions on Python Fundamentals

120+ MySQL Practice Questions

90+ Practice Questions on List

50+ Output based Practice Questions

100 Practice Questions on String

70 Practice Questions on Loops

70 Practice Questions on if-else


Disclaimer : I tried to give you the correct coding of ” Print Hello World in Python” , but if you feel that there is/are mistakes in the code or explanation of “Print Hello World in Python “ given above, you can directly contact me at csiplearninghub@gmail.com.


Share with others

Leave a Reply

%d bloggers like this: