Notice: This page requires JavaScript to function properly.
Please enable JavaScript in your browser settings or update your browser.
Lära Challenge | Strings
Introduction to Python | Mobile-Friendly

book
Challenge

Suppose you are given the variables name (as a string) and age (as an integer). You need to output the message in the following format "name is age y.o." using concatenation.

question-icon

Fill in the blanks to complete the task.

# Variables
name = "Jim"
age = 34

# Output the message
print(
_ _ _
_ _ _
_ _ _
_ _ _
_ _ _
_ _ _
_ _ _
_ _ _
_ _ _
_ _ _
)
Jim is 34 y.o.

Click or drag`n`drop items and fill in the blanks

dots
age
dots
str
dots
+
dots
int
dots
name
dots
" is "
dots
(
dots
)
dots
+
dots
+
dots
" y.o."

Var allt tydligt?

Hur kan vi förbättra det?

Tack för dina kommentarer!

Avsnitt 3. Kapitel 5

Fråga AI

expand
ChatGPT

Fråga vad du vill eller prova någon av de föreslagna frågorna för att starta vårt samtal

some-alt