This post may contain affiliate links.
In this simple lego coding game, students will learn about two important coding concepts: sequencing and loops. Even young children can learn the basic concepts of coding using our simple unplugged coding activities.
All you need for this simple coding activity is some LEGO. This coding activity only takes a few minutes to set up.
What coding concepts are learned?
Students will learn about loops and sequencing in this coding activity.
Sequencing refers to the order of steps. It’s important to get the order of steps correct if you want your computer to perform the task correctly. Imagine brushing your teeth before putting on the toothpaste! The order of steps is very important.
A loop is a set of instructions that repeats and repeat itself until a specific condition is met. Loops help make our instructions more efficient. Instead of telling us to brush our teeth back and forth, back and forth, back and forth, back and forth, we say ‘brush your teeth for one minute’ or ‘brush your teeth until your teeth are clean’. Loops help us to shorten our instructions.
List of Materials
- LEGO which can be configured into patterns. You will need multiples of each piece you choose. We prefer classic bricks for this activity such as 4×2 and 2×2 bricks.
- Paper and a pencil
How to set up this coding activity
Start by making some patterns with your lego. Pictured below are some examples that we created. The older your child, the harder the pattern you can make. For older children, you can combine multiple patterns together.
How to play:
There are two ways to play this game
Method 1: Back to Back
In this method two students will work together to recreate the patterns of LEOG. Students will need to be sitting back to back so that they can’t see what the other is doing. Student 1 will be holding the patterned LEGO and the Student 2 will have the pieces of lego needed to make the pattern on their desk.
The goal of the game will be for Student 1 to give the instructions on how to create the lego pattern using a LOOP. Student 1 will instruct their partner on how to build the first part of the pattern and then use the term REPEAT to create a loop that will finish the pattern.
E.g. of instructions for the LEGO structure below:
Method 2: Writing out instructions
This method can be played alone. Students will need to write out instructions needed to create the LEGO for each of the patterns they are presented. They should aim to do this using a LOOP so that there are as few lines of instructions as possible.
E.g. of instructions for the LEGO structure below would be:
Students should now understand the concepts of loops. By adding loops to our instructions we can give the instructions much faster in a way that’s easier to understand.
Students will also get to know the concept of sequencing. When creating a pattern, its important to get the sequence of steps right or the final product will not look right.
If students make a mistake during this activity get them to ‘debug’ their work. In computer programming, mistakes are referred to as ‘bugs’. Bugs are common in computer programming and ‘debugging’ our work is an important step in learning to code.
Pin for Later!
Katie is mom of two rambunctious boys and a self-proclaimed super nerd. With a background in neuroscience, she is passionate about sharing her love of all things STEM with her kids. She loves to find creative ways to teach kids computer science and geek out about coding and math. You can find her blogging at Teach Your Kids Code.