A simple program that displays “Hello, World!”. It’s often used to illustrate the syntax of the language.
To understand this example, you should have the knowledge of the following Python programming topics:
Source Code
# This program prints Hello, world!
print('Hello, world!')
Output
Hello, world!
In this program, we have used the built-in print() function to print the string Hello, world! on our screen.
By the way, a string is a sequence of characters. In Python, strings are enclosed inside single quotes, double quotes, or triple quotes.
Related posts:
Python iter()
Python Program Read a File Line by Line Into a List
Python Dictionary setdefault()
Python issubclass()
Python Generators
Python File I/O Operation
Python sorted()
Python Set intersection_update()
Python Strings
Python String isnumeric()
Debug a JavaMail Program
Python Program to Check if a Number is Positive, Negative or 0
Python time Module
Python String replace()
Python Statement, Indentation and Comments
Python Program to Get the Full Path of the Current Working Directory
Python Program to Find the Largest Among Three Numbers
Python List Comprehension
Python Program to Merge Two Dictionaries
Python Program to Check the File Size
Python property()
Python Set issuperset()
Python pow()
Python bin()
Python Input, Output and Import
Python classmethod()
Python Program to Display Calendar
Python String join()
Python String casefold()
Python Program to Display Powers of 2 Using Anonymous Function
Python List index()
Python dict()