Define a block
Section 11: My Blocks: make a new blockLesson 11.1 · ⏱ 8 min
In My Blocks make a block with a name you choose, like “square”, and put its steps under define once. After that, use the new block whenever you like, like any block in the program.



📌 Note
Think: how many blocks would you need without “square”? And if you wanted to make all the squares bigger, how many places would you change now? Only one: inside define.
📌 Another example: a “star” block
We define the star once, then use it 3 times with only three blocks instead of 3 × 4 blocks.



✍️ Practise
Make a “line” block that draws a line 100 long, and use it 3 times.
✍️ Practise here in the lesson✖ Close the labor open the lab in a new page ↗
🎯 Challenge yourself
Easy
Make a “triangle” block and draw a row of 4 triangles.
👀 Show the solution🙈 Hide the solution



Medium
Make a “jump” block (up, then down), and use it inside repeat 3.
👀 Show the solution🙈 Hide the solution



Hard
Make a “circle” block and draw 5 coloured rings with it, overlapping.
👀 Show the solution🙈 Hide the solution




