Experiment, and Where to Go Next

Run a few friendly lines, then celebrate "" you're officially a programmer now.

7 min read · runnable Python

You ran your first line of code in the last lesson. Let's stretch a little further and combine a few ideas you've learned "" using real Python this time.

A few lines, working together

The code box holds this small program:

name = "friend"
print("Hello, " + name + "!")
print("You ran real code today.")

Look how much of this you already understand:

  • Line 1 creates a variable called name and stores the text "friend" in it. (Just like the labeled boxes from Module 2!)
  • Line 2 joins three pieces of text together with + and prints the greeting. Joining text with + is exactly what you saw in pseudo-code.
  • Line 3 prints a second message. The lines run in sequence, top to bottom "" another idea you already know.

Press Run. You should see:

Hello, friend!
You ran real code today.

Make it yours

Try these small changes, running after each one to see what happens:

  1. Change "friend" to your own name, inside the quotes.
  2. Add a third print(...) line with a message of your choice.
  3. Change the wording of any message.

Experimenting like this "" change something, run it, see what happens "" is exactly how programmers learn. You're already doing the real thing.

Tip: If you get an error, read it as a friendly hint, not a scolding. Most beginner errors come from a missing quote, a missing parenthesis, or a misspelled word. Check those three first and you'll fix the great majority of problems.

Look how far you've come

Take a breath and notice what you now understand. You can explain:

  • what a program and code are,
  • what a computer actually does,
  • what a programming language is,
  • variables, sequence, input and output, decisions, and loops,

...and you've run real Python. That's a genuine foundation. Every programmer you admire started right about here.

Where to go next

From this gateway, the natural next step is to pick one language and go deeper "" Python is a wonderful first choice, and Gwecode has a full beginner path waiting for you. The concepts you learned here will show up again and again. You'll recognize old friends in new clothes.

Be proud. You started, and starting is the hardest part. Welcome to programming.

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

Quick check

Q1 In name = "friend", what is happening?

Q2 If your code gives an error, what's the best first reaction?

Want to save your progress? It's free.

Create a free account