Investigating variations using the Sorting Network
Children test the sorting network with repeated numbers and with other things to sort, and predict what will happen.
Steps
- Recap how the network works.
- Use cards where two values are equal. Ask what happens when equal cards meet.
- Predict, then run the network. Equal cards end up next to each other.
- Choose something new to sort, like heights or the alphabet. Decide what 'smaller' means for it.
- Run the network with the new cards and check the result.
- Discuss what stays the same each time and why.
Talk about it
- Did your prediction match?
- What else could you sort?
- What if the rule for smaller changed?
CC BY-SA 4.0
Adapted from CS Unplugged by the University of Canterbury Computer Science Education Research Group (CS Unplugged), licensed CC BY-SA 4.0.
Original lesson, with pictures · License: CC BY-SA 4.0
There are no pictures here. The original lesson has the pictures and printables.
Changes made: Simplified, shortened and translated by Open Cosmos with AI
This adapted lesson is shared under the same license (CC BY-SA 4.0).