0%
⭐ 0 XPPractice
Pack 1 · Challenge 4 of 5 · 10 XP · ⏱ 4 min

Shout Box

📣 len() counts things: the letters in a word, or the items in a list.

word = "pizza"
print(len(word))
5

Glue a number into text with str(): "I have " + str(3) + " lives".

Instructions

  1. Ask input("Say it: ") and store it in word.
  2. Print word in capitals with !!! on the end, like HELLO!!!
  3. Print That was 5 letters. using len(word).
💡 Hint

word.upper() + "!!!" for the shout. For the count: "That was " + str(len(word)) + " letters."

Ask the community

bot.py
Terminal
← BackNext →

Python Warm-ups

All practice packs

Talk it out

  1. Read the instruction with the ✗ out loud.
  2. Say what your code does, line by line, as if to a friend.
  3. Find the line where what it does and what you want split apart.
  4. Press Run and read the terminal. Is that what you expected?
  5. Still stuck? Press Ask Pip why, or peek at the solution.
  6. Or ask on the community help board: say which quest, and paste your code.
New badge!

Your bot just got a new part. See it on the quest map.

Name your bot

It levels up as you play, and gets a new part with every chapter.