Skip to content
Lesson 1 of 9 Free Preview
Duration: 15 min

Setting Up and Your First Script

Learn it

Python is used by scientists, game studios and web companies. Install it free from python.org (includes IDLE), or use a browser editor. A script is a .py file run from top to bottom.

🧰 Tool: any free online Python editor such as Online Python or Trinket, or install Python from python.org and use IDLE.

Code examples

Python

# hello.py
print("Hello, world!")
print("Python version check:", 3 + 0.11)
name = "Ada"
print("Welcome,", name)
Run from a terminal

python3 hello.py

Project: Get set up

  1. Install Python or open an online editor.
  2. Create hello.py and run it.
  3. Change it to print three facts about you.

Challenge: Run python3 in a terminal and try commands interactively (the REPL).

Enjoying this lesson?

Enroll in the full course to access all lessons, track your progress, and earn a certificate.

Enroll in Full Course