Computer ScienceGrades 6-8Intermediate

    Robot Pathfinding Algorithms

    Teaching computers to navigate from A to B efficiently

    60 minPairs5E Model

    Lesson Overview

    Students explore pathfinding algorithms through an unplugged grid activity, implement a simplified shortest-path algorithm in block or text-based code, and connect their work to real-world robotics and GPS navigation β€” aligned to CSTA 2-AP-10, 2-AP-11, and 2-DA-07.

    Learning Objectives

    Students will be able to:

    • Explain what an algorithm is and evaluate algorithms based on efficiency
    • Trace through a pathfinding algorithm on a grid and predict its output
    • Implement a robot navigation program using loops and conditionals
    • Analyze why different paths have different costs and explain trade-offs

    Lesson Phases (5E Model)

    • 1Show 10-second clips: Google Maps finding a route, a warehouse robot navigating shelves, a Mars rover avoiding rocks
    • 2Ask: 'What do all of these have in common? What problem are they solving?'
    • 3Human algorithm: Draw a simple grid on the board, mark START and END, place 3 obstacle cells
    • 4Ask a student volunteer to trace a path β€” then ask class: 'Is that the shortest path? How do you know?'
    • 5Introduce the lesson: 'Today we'll teach a computer how to find paths β€” just like GPS and robots do.'

    Assessment Strategies

    Grid Pathfinding Worksheet

    Evaluated on correct path traces, accurate cost calculations, and algorithm identification

    Flowchart

    Scored on correct logic flow, proper decision diamond usage, and connection to code

    Navigation Program

    Does the robot successfully navigate? Does the student explain WHY their approach works or fails?

    Extension Activities

    • β†’Research Dijkstra's algorithm and A* β€” the algorithms used in real GPS and game AI
    • β†’Map your school building as a grid β€” design a robot path from cafeteria to library
    • β†’Use the Code Academy robotics lessons to continue building navigation skills
    • β†’Explore how self-driving cars handle dynamic pathfinding (obstacles that move)

    At a Glance

    Grade BandGrades 6-8
    Duration60 min
    Group SizePairs
    DifficultyIntermediate
    SubjectComputer Science
    Lesson Model5E Instructional Model

    Materials

    • Grid pathfinding worksheets (10Γ—10 grid with obstacles)1 per student
    • Colored pencils or markers1 set per pair
    • Devices for coding (Code Academy or Scratch)1 per pair
    • Robot cards (showing different path costs)1 set per pair
    • Algorithm flowchart template1 per student

    Key Vocabulary

    Algorithm
    A step-by-step set of instructions for solving a problem or completing a task
    Pathfinding
    An algorithm that finds a route from one point to another
    Efficiency
    How well an algorithm accomplishes its task using minimal resources (time, steps, memory)
    Node
    A point on a graph or grid that can be a start, end, or waypoint
    Cost
    A measure of how expensive (slow, far, or difficult) a particular path is to travel

    Standards Alignment

    CSTA
    2-AP-102-AP-112-AP-132-DA-07

    CS Teachers Association K-12 Standards

    Digital Tools

    • β†’Code Academy β€” Robotics & Algorithms Lessons
    • β†’Code Academy: Complex Logic Challenge

    Bring this curriculum to your school

    Schedule a meeting with our team to discuss district-wide implementation.