Rullst AcademyRullst Academy/Lesson
Python: from first line to project · Lesson 02 / 12

Names that carry meaning

Tico planned ten minutes of study and gained five more. A name in the program lets us track that value without repeating the whole story.

Learning paths9 min

Let's discover together

  1. 1

    minutes = 10 binds the name minutes to the integer 10. The = sign assigns; it does not ask whether two values are equal.

  2. 2

    In minutes = minutes + 5, Python evaluates the right side using the current value, then updates the name. The new value is 15.

  3. 3

    10 is an integer; "10" is text (str). Adding numbers calculates; + joins strings: "10" + "5" produces "105". The quotes are not part of the text displayed by print.

  4. 4

    True and False are boolean values, capitalised in Python. Use clear, consistent names; minutes and Minutes are different names.

✦
YOUR MISSION

Assign and update values; distinguish numbers, text and booleans.

Now it's your turn

Discovery workshop

Read, predict, check

Compare the two versions. Show result reveals a prepared output: this panel does not run Python. Then practise with the activity file.
Mini experiment

Learning simulation: compare cards and check your predictions. The browser is not compiling Rust or starting a server.

minutes = 10
minutes = minutes + 5
print(minutes)
Build your answers and check when you are ready.
A moment to understand

Why do the two versions show different results?

I need a hint

Look for quotes before interpreting +.

Loading your journey…

Take it with you

In the file, create minutes = 20 and add 7. Write your prediction before running. Then try two quoted strings and explain the difference.

PYTHON · .py

Your Python workbench

Here you read and predict prepared outputs. To run the actual code, download the activity file, edit it on your computer and use Python. Rullst Academy grades lesson answers; it does not verify local execution.

Save and run

Extract the activity ZIP into its own folder. Open a terminal there and use your system’s command. If downloading your edited file separately, use its actual name in the command. Save before running again.

Windows
python lesson.py
macOS / Ubuntu
python3 lesson.py
My files and GitHub

The editor keeps a local draft and can send a .py file to GitHub with your confirmation. Download your edited code to preserve it. The ZIP is starter material; for the final project, also publish data and test files following PUBLISH.md.

At your own pace

My files and GitHub

Every lesson can become your own record: code, notes or a practice plan. Saving a file to GitHub is optional and does not change your XP.

Student guide

The editor and downloads open when this lesson is available to your account. Check access below or return to the track map.

Checking your access to this lesson…

Rullstpetbot

AI can make mistakes. Check the lesson material.