This post shows you how to create your first simple program in Python that outputs or displays “Hello, World!“. It is often used to illustrate the basic syntax of the language for a working program.
Make sure that you have installed Python in your machine. If you do not have it yet, you can download it on this page.
2. Create Hello World Program
- Let create your first Python file, called
helloworld.pyand then use
print()function to output a string.
- Open your command line where you saved the file, and run the below command.
- If you did it right, you should see “Hello, World!” in your command line.
Congratulations, you have created and executed your first Python program.