Activity 01
Pair Programming: Stack Implementations
Pairs implement array-based and linked-list stacks in pseudocode or Python, adding push, pop, and peek methods. They test with sequences of operations and measure simulated time costs. Compare results in a shared class document.
How can real-world networks be represented as graphs?
Facilitation TipDuring Pair Programming: Stack Implementations, circulate and ask students to explain why their chosen implementation handles edge cases like full arrays or null pointers.
What to look forPresent students with two code snippets: one implementing a stack using an array and another using a linked list. Ask them to identify one advantage and one disadvantage of each implementation in terms of memory usage and performance for a large number of operations.