Step 2 of 4
Values, text and numbers
Step 2 · Try it · 8 minStep 2 · 8 min
Sample: Try it: values and text
A variable is a name for a value. Run the cell, then change the city and run it again.
Box 1, not done yet
You should see
Welcome to Riyadh
f-strings put values inside text: write f before the quote and the name in braces.
Box 2, not done yet
You should see
3 hours of practice
Numbers do arithmetic. Multiplying by a number with a decimal point gives a float.
Box 3, not done yet
You should see
50.0
Every value has a type. These are the three you will meet most.
Box 4, not done yet
You should see
int float str
Press ▶ on every box and check you see what it says. Change anything you like.
Carry on with Sample: Python foundations
Your progress and certificate are kept.