For a quick start and to get to know the integrated development environment (IDE), developers traditionally program the output of "hello world" at the beginning:

  1. Start Python IDLE (Integrated Development and Learning Environment has been included with the installer for the Python programming language)

    Searching for Python => IDLE will be offered

  2. The Python Shell is opened now.
    Simply type the instruction
    print("Hello world!")
    The output is
    Hello world!
    "Hello world!" in Python Shell


    Variable in Python ShellAs you can see you can program directly in the shell. Even things like the deklaration and initialisation of variables are possible.

    However, all values are only valid temporarily and are lost when the shell is closed. Therefore longer programs are stored in files.

  3. Create a new file (File > New File) and edit the same instruction:
    print("Hello world!")
    Save the file with extension .py and run the program (Run > Run Module).

    "Hello world!" output from progrem hello.py
    Output of program python.py






Last modified: Wednesday, 2 October 2019, 3:21 PM