1 of 10

The Arizona STEM �Acceleration Project

2025

2 of 10

Maze Challenge: Introduction to Coding and Problem Solving

In this lesson, 4th grade students will explore foundational coding concepts and develop problem-solving skills by navigating programmable robots or coded paths through mazes. Students will learn about algorithms, sequences, and debugging while working collaboratively.

Jaszie Pena

A Fourth-Grade STEM Lesson

The Arizona STEM Acceleration Project

3 of 10

Notes for Teachers

List of Materials

Prior to the lesson, set up maze materials or program virtual maze platforms (e.g., Code.org, Scratch, or Bee-Bots if available).�

This lesson can be taught using physical mazes or computer-based platforms depending on your classroom resources.�

Encourage teamwork and iteration.

Printed maze maps or masking tape for floor mazes�

Coding cards or block coding platforms (e.g., Scratch, Code.org)�

Robots (optional): Bee-Bots, Ozobots, or Dash�

Whiteboards and markers for planning�

Student notebooks

STEM/Coding Book to engage

Copies of the Exit Ticket- Click here

I used:

  • Anchor Chart paper
  • Poster Markers
  • Edison Robots
  • Coding Cards
  • Book- Rox’s Secret Code

4 of 10

Standards

Arizona Computer Science Standards:

  • CS.4.AP.01: Develop programs with sequences and simple loops, to express ideas or address a problem.�
  • CS.4.AP.03: Use logical reasoning to predict the behavior of programs.�
  • CS.4.AP.04: Debug errors in an algorithm or program that includes sequences and simple loops.�

Arizona Science Standards (Cross-cutting Concepts & Science and Engineering Practices):

  • 4.P4U3.3: Ask questions and investigate ways to solve a problem.�
  • Engineering Practice: Define a simple design problem reflecting a need or a want that includes specified criteria for success.

Arizona Math Standards:

4.MD.A.2

Use the four operations to solve word problems involving distances, intervals of time, liquid volumes, masses of objects, and money, including problems involving simple fractions or decimals, and problems that require expressing measurements given in a larger unit in terms of a smaller unit. Represent measurement quantities using diagrams such as number line diagrams that feature a measurement scale.

4.MD.A.1

Know relative sizes of measurement units within one system of units including km, m, cm; kg, g; lb, oz; l, ml; hr, min, sec. Express measurements in a larger unit in terms of a smaller unit. Record measurement equivalents in a two-column table.

4.OA.A.3

Solve multistep word problems posed with whole numbers and having whole-number answers using the four operations, including problems in which remainders must be interpreted. Represent these problems using equations with a letter standing for the unknown quantity.

4.OA.C.5

Generate a number or shape pattern that follows a given rule. Identify apparent features of the pattern that were not explicit in the rule itself.

5 of 10

Objectives:

Learn how to write and follow algorithms (coding sequences).�

Apply logical reasoning to solve maze problems.�

Work collaboratively to debug and improve solutions.

6 of 10

Agenda (60 minutes)

  1. Intro & Driving Question (10 mins)�
  2. Activity Instructions & Demonstration (5 mins)�
  3. Hands-on Maze Challenge (35 mins)�
  4. Reflection and Assessment (10 mins)�

7 of 10

Intro/Driving Question/Opening

Driving Question:� How can we give a computer or robot a set of instructions to solve a maze?

Discussion Prompt:

  • What is coding?�
  • Why do we need to follow a sequence when giving instructions?

8 of 10

Hands-on Activity Instructions

Group Structure:

  • Students work in pairs or small groups.�

Step-by-Step Instructions:

  1. Present a sample maze and demonstrate how to move a character/robot using directional commands (e.g., forward, turn left).�
  2. Groups plan their route through the maze on whiteboards or in notebooks.�
  3. Using coding cards or block coding platforms, students "program" the route.�
  4. Students test their code with either paper mazes or robots.�
  5. If unsuccessful, they debug and revise their instructions.�
  6. Share successful solutions with the class. Have students present and give feedback.

My Classroom:

Beginner Level- Students used mazes I created in block coding to solve the mazes.

Mid Level- Students went into scratch coding to solve the mazes.

Advance Level- Students created their own mazes and worked in a variety of platforms to code the maze in one line of code.

9 of 10

Assessment

Observe group collaboration and problem-solving. I usually like to have a clipboard of this to take notes of what groups are working well and who might need some assistance. �

Exit Ticket: What is one challenge you faced while solving the maze, and how did you overcome it?

Click here for Exit Ticket

Optional: Students write or draw their coded path in sequence form.

10 of 10

Differentiation

Remediation

Extension/Enrichment

  • Use simpler mazes or step-by-step guided coding cards.�
  • Pair with peer mentors.

  • When checking in with students, offer more scaffolding to groups who need it.

  • Add loops to reduce the number of instructions.�
  • Design their own mazes and swap with classmates.�
  • Try programming with more complex block code on Scratch.