Your First Program

Make the computer say hello

6 min read · runnable Python

Welcome! You're about to write your very first computer program. It's going to be tiny, and that's exactly the point. Everyone starts here.

In Python, when we want the computer to show us something on the screen, we use a tool called print. Think of print as a way of telling the computer: "show this to the person watching."

How it looks

Here is the most famous first program in the world:

print("Hello, world!")

Let's break that down piece by piece, because every part matters:

  • print is the command — the instruction we're giving.
  • The round brackets ( ) hold the thing we want to show.
  • The quotation marks " " wrap around text. Anything inside quotes is treated as plain words, not as a command.

So print("Hello, world!") means: "show the words Hello, world! on the screen."

Tip: The words inside the quotes can be anything you like. The computer doesn't read them or judge them — it just shows them back to you exactly as written.

Your turn

Run the code on the right by pressing the run button. You should see the message appear below it. Then try changing the words inside the quotes to your own name or a silly sentence, and run it again.

That feeling of changing something and seeing the result? That's programming. You've already started.

Try it yourself
Output
Press “Run code” to see the result.

Quick check

Q1 What does print("Hello") do?

Q2 Why do we put quotation marks around Hello, world! ?

Want to save your progress? It's free.

Create a free account