An algorithm is a repeatable process that delivers an expected result. Computer scientists use algorithms to provide well-defined instructions to computers to solve a problem or perform a task.
However, students can define precise, repeatable processes for problem-solving in many classroom contexts. For example, teachers have utilized algorithms to help students discern whether an organism is alive and to identify phases of the moon.
We have identified three sub-practices of creating algorithms. These sub-practices may occur in combinations that connect with one another. For instance, if a student is programming, they are using code to define procedures as algorithms, so these are not necessarily distinct steps.
- Defining Procedure as Algorithms by identifying parts of a process and expressing the procedure in a manner that can be comprehended by computational tools (e.g., flow charts, pseudocode).
- Programming a computer program for a specific purpose using a language of your choice (text- or block-based).
- Testing and Debugging a computer program by identifying errors and repairing the errors to produce a functioning program that meets a designated purpose.
Download the Resources
Explore the resources below to consider how to integrate algorithms in your classroom.
How algorithms can be used in the classroom
Learn how our partners Ashley Simpson and Niki Cosper, teachers in Talladega County Public Schools, helped students develop algorithms to identify, sort, and categorize objects in their middle school science classrooms.
“When we look at algorithmic thinking, we’re looking at that ‘step-by-step.’ We had our compounds, mixtures, and elements. My students had to organize them accordingly using questions to figure out where everything went into place.” – Ashley Simpson
“If you’re teaching a process like determining if things are living or non-living, that’s a great time to bring an algorithm because students can come up with the decision matrix, yes/no questions, and come up with their own ways to evaluate if something’s alive.” – Niki Cosper
Look Fors
Teachers will know that students are creating algorithms because they may observe the following student actions:
- Decomposing problems or tasks
- Identifying essential steps
- Coding
- Identifying and repairing errors
- Considering efficiency
Prompting Questions
Ask students to engage in creating algorithms and/or reflect on their process or progress with these prompting questions:
- What do you need to know to be able to solve this problem/do this task?
- What should be the result of the problem or task?
- What is required to solve this problem/do this task?
- Why is each step required to solve the problem/task?
- Does adding/removing a step affect your results?
- Would you include additional words or details to explain this process to a partner?
- Does each step have the result you intend?
- Does a partner testing your algorithm get the same results as you?
- Are there certain inputs where you do not get the intended result?
- Can your algorithm have the same result with less steps?
- Do you notice any patterns in your procedure?
Resources and Examples
Explore examples of middle school science activities integrated with computational thinking practices. Although the examples are topic-specific, templates are available for you to design opportunities in different topics or contexts.
Identify, Sort, and Categorize Objects
In this example, a student observed plants at a park over a year. They created an algorithm to help others identify plants they find in the same area by considering what they look like and when and where they were collected. Explore the resource to see how the student utilized algorithms to identify, sort, and categorize plants.
Want to do something like this in your classroom? Use or adapt this template as a resource to design opportunities for your students to use algorithms to identify, sort and categorize objects.
Troubleshoot a Design Problem
In this example, a student completed the
circuit arcade activity. Then, they created an algorithm to help others troubleshoot why a lightbulb in a circuit may not be lighting up. Explore the resource to see how the student utilized algorithms to troubleshoot a design problem.
Want to do something like this in your classroom? Use or adapt this template as a resource to design opportunities for your students to use algorithms to troubleshoot a design problem.
Illustrate a Phenomenon
There are many predictable events that occur in the natural world, such as life cycles, chemical reactions, or Earth’s processes. One way to illustrate these phenomena is by programming an algorithm. If your algorithm represents a mathematical relationship between parts of a system, it may be a computational model. If there are no input/outputs or defined mathematical relationships, you are likely simply illustrating a scientific phenomenon. See the resources for Creating Computational Models below to learn more about how your illustration could be modified to become a computational model.
In this example, a student used block-based programming in Scratch to illustrate a simple food chain with a producer, herbivore, and carnivore by programming in Scratch. Explore the resource to see how the student programmed an algorithm to illustrate a scientific phenomenon.
Want to do something like this in your classroom? Use or adapt this template as a resource to design opportunities for your students to use algorithms to illustrate a phenomenon.
Assessment
The following rubrics outline components of creating algorithms that can be utilized to assess student work.
Defining Procedures as Algorithms
Defining Procedures as Algorithms
| "Yes" | "Almost" | "Not Yet" |
Algorithm Planning |
Identifies a problem to be solved through the algorithm and the output of the algorithm.
| Identifies a problem to be solved through the algorithm, but does not fully describe the problem or the output. | Does not identify a problem to be solved through the algorithm. |
Flow Chart Diagram | Original flowchart creates a logical scenario and generates a tree of possible solutions. The flowchart shows layers of thinking beyond a yes/no question to demonstrate deeper decisions that rely on previous information. The flowchart includes at least three different conditional decisions and user input.
| Original flowchart includes a series of decisions but the example does not show the complexity of decisions that are available. Fewer than three conditional decisions are included, decisions are limited to yes/no, or the algorithm doesn’t consider user input. | A decision was selected, but there does not seem to be enough to connect decisions and outcomes. |
Programming
Programming
| "Yes" | "Almost" | "Not Yet" |
Description of Program Purpose and Results | Describes in detail the purpose of the program and what will result when the program is run and different inputs are selected. | Provides general information but insufficient details about the purpose of the program and what will result when the program is run and different inputs are selected. | Does not describe the purpose of the program and what will result when the program is run and different inputs are selected. |
Identification of Steps | Identifies a detailed set of logical, sequential steps leading to the desired outcome of the program. | Partially identifies a set of steps leading to the desired outcome of the program. | Does not identify a set of steps leading to the desired outcome of the program. |
Artifact functionality | Program functions to solve the intended problem. The program runs from beginning to end without bugs. | Program runs partially, but it does not achieve the intended purpose or has bugs. |
The program does not run as intended.
|
Program Requirements* | The program includes a triggering event, user input, at least two conditions, and a value stored as a variable and used within the program | The program includes one or more of the required elements, but it does not include all requirements. | The program does not include any of the required elements. |
*Teacher Note: Adapt or replace with program requirements specific to your assignment
Testing and Debugging
Testing and Debugging
| "Yes" | "Almost" | "Not Yet" |
Identifying Bugs | Identifies bugs in the program and ways the algorithm doesn’t perform as expected or could be more efficient. Provides details about how the parts of the program needs debugging.
| Identifies bugs in the algorithms, but does not sufficiently describe the parts of the program needing debugging. | Does not identify bugs in the program. |
Working solution | Provides working code that is free of bugs. | The code is functional, but certain inputs are not compatible. | Does not provide working code. Code still has bugs. |
Tools
Explore this curated list of supports to implement, explore, and promote computational thinking practices in your classroom.
Defining Procedures as Algorithms:
- LucidChart: Platform to visualize processes with collaborative capabilities
- SmartDraw: Platform to create flowcharts, organizational charts, drawings and/or floorplans
- Draw.oi: Platform to create and share professional diagrams[/accordion-item][/accordion]
Programming: