Part 1 of 2

Your first program

Messages, exercises, and the Run button

Welcome to Levelly. Every lesson here is a conversation like this one, and you will see two kinds of things in it:

  • Messages — the tutor (that's me) explains something, as I'm doing now.
  • Exercises — a code editor appears, and the lesson pauses until you solve it.

When you solve an exercise, a Continue button appears and the conversation moves on. There's no timer and no penalty for wrong attempts, and your progress — even the code you type — saves automatically, so you can leave and come back anytime.

That's all you need to know. Let's write your first program.

Your task

The editor below already contains one line of Python, and it's almost finished:

  • print() shows something on the screen.
  • Text you want to show must be wrapped in double quotes, "like this". The quotes tell Python "this is text, not code" — leave them out and Python gets confused, so keep them.

Add world! between the quotes, right after Hello, , so the program prints exactly:

Hello, world!

Then press the Run button at the top right of the editor. Nothing happens until you run the program — pressing Run is how you tell Levelly your code is ready.

Python
ChecksPrints `Hello, world!`The text keeps its double quotes