Session 1: Factorial and Loop Invariants · 45 minutes
Focus: multiplicative accumulation
Checkpoint: 0! is 1 because zero iterations retain the identity.
Teaching the visible machine
Describe and inspect factorial, Fibonacci and reverse-copy invariants.
Total classroom time: 135 minutes · 3 × 45 minutes
prepare factorial examples0,4,6; two number cards for Fibonacci1,1; memory source0..3 and destination16..19. Limit factorial to tested small inputs and explain safe-integer limits.
Focus: multiplicative accumulation
Checkpoint: 0! is 1 because zero iterations retain the identity.
Focus: bounded Fibonacci sequence
Checkpoint: first six are 1,1,2,3,5,8 and a temporary prevents lost state.
Focus: reverse-copy four bytes
Checkpoint: destination4,3,2,1 while source1,2,3,4 stays unchanged.
provide variable-role labels and one completed state transition; allow pair narration before typing.
explain why equality against100 never bounds Fibonacci; reason about overlapping source/destination before attempting an in-place algorithm.
two algorithm traces plus a correct reverse-copy invariant, distinguishing reverse copy from in-place reversal.
OpenKernel EDU aligns with concepts in the following frameworks. These connections support teacher planning. Check your current local grade or course expectations and assessment requirements when selecting activities.
Coding and computational thinking in elementary mathematics; algorithms, programming, data representation and computer systems in secondary computer studies/digital technology contexts.
Units 1–3 address state/data/computers, 4–8 sequence/control/algorithm/debugging/representation, and 9–10 decomposition/systems/projects. Select actual grade/course expectations locally. This model does not establish coverage of all mathematical, digital citizenship, hardware-building or networking outcomes.
Applied Design, Skills and Technologies learning through designing, testing and refining solutions; secondary computer studies/programming concepts involving algorithms, data and computer systems.
Units 4–10 support iterative program design and explanation; units 1–3, 8 and 9 support data/state/system representation. Paper design, trace evidence and reflection make the process visible. Check current grade/course wording; not every ADST competency is covered.
Computing science in applicable science/programming contexts; senior-high Career and Technology Studies Computing Science (CSE) concepts in algorithms, structured programs, data and systems.
Units 1–8 develop state, control and abstraction; units 9–10 apply decomposition and testing. Check the current program of studies and course requirements when deciding which activities suit your class.
These concept references use the CSTA 2017 framework. Check the current adopted edition and the full standard’s grade-level scope before using an identifier in a formal school mapping.
Units 1–3, 8 and 9 also connect to the Computing Systems concept. Algorithm, state, debugging, abstraction and control describe the ideas taught in this resource; consult the local framework for its expectation names and scope.
Use these official landing pages to check the current adopted edition and local grade or course expectations.