Activity 01
Pair Coding: Time Complexity Races
Pairs implement linear search and binary search on arrays of varying sizes, time each run with stopwatches, and plot results on graphs. They discuss why binary search scales better. Extend by adding space measurements.
Analyze how Big O notation helps predict an algorithm's scalability.
Facilitation TipDuring Pair Coding, circulate to ask pairs to explain why their algorithm’s time grows as it does, not just to finish first.
What to look forPresent students with short code snippets or pseudocode for simple algorithms (e.g., finding the maximum value in an array, nested loops). Ask them to identify the Big O notation for time complexity and briefly explain their reasoning.