Python Programming Language

Python Hello World Program

By

First published on February 27, 2019


Hello World Program

If you have Python, you can try a Hello World program. Examine a simple Python program called HelloWorld.py

print 'Hello World!'

This is a simple program. There are no special structures, so no indentation spaces are required. The file name would end in .py

Create your program in a text editor and name it: HelloWorld.py

To run the program. type into your terminal:

python HelloWorld.py

The output should be:

Hello World

Congratulations if you can create this program and run it. You are now a Python programmer!

Leveling Up

  • Modify the program by writing additional lines of text.
  • Ask yourself, how is a computer program different from a web page? (Keep this question in mind as you learn more.)

| COURSE |


Content is copyright the author. Layout is copyright Corsbook. See Corsbook.com for further notices.