---
id: "{{ID}}"
title: "{{TITLE}}"
type: "BELL_RINGER"
created_by: "Curriculum OS Builder"
phase: "{{PHASE}}"
deliverable: "P3-T16"
version: "{{VERSION}}"
date: "{{DATE}}"
template_contract: "artifact-template-v1"
template_required_sections:
  - "Weekly Objective & Schedule"
  - "Day 1 (Monday): Mental Model Recall & Analogy"
  - "Day 2 (Tuesday): Rapid Code Tracing"
  - "Day 3 (Wednesday): Quick Bug Hunt (Spot the Defect)"
  - "Day 4 (Thursday): Visual Diagram Tracing"
  - "Day 5 (Friday): Creative Synthesis & Bridge Forward"
  - "Teacher Answer Key & Scoring Guide"
---
<!-- INJECT_BODY -->

# WEEKLY BELL RINGERS (5-DAY WARM-UP PACK): [UNIT / LESSON TITLE]
_Unit: U[X] | Module: M[X.X] | Time: Exactly 3-5 Mins at Start of Each Session_

## Weekly Objective & Schedule
- **Weekly Core Theme:** [E.g., "Swift Concurrency, Actors & Thread Safety"]
- **Routine Protocol:** Display prompt on projector immediately as students enter. Students write responses in their Daily Journal before class discussion.

---

## Day 1 (Monday): Mental Model Recall & Analogy
> *Time: 3 Mins | Bloom: Understand*

**Prompt:**  
[Present a quick thought experiment connecting real life to code. E.g., "Imagine a physical whiteboard in a classroom. If 5 students try to write on the exact same spot at the exact same second, what happens? How does an Actor prevent this in software?"]

- **Student Journal Box:**  
  ```text
  [1-2 sentences on race conditions vs. serialized mailboxes]
  ```

---

## Day 2 (Tuesday): Rapid Code Tracing
> *Time: 4 Mins | Bloom: Apply*

**Prompt:**  
What is the exact output printed to the console when this snippet runs?
```swift
func compute() async -> Int {
    var total = 10
    Task { total += 5 }
    return total
}
```
- **Question:** Why might the returned value be `10` instead of `15`?
- **Answer Area:** `[Explain unstructured task detachment and race condition]`

---

## Day 3 (Wednesday): Quick Bug Hunt (Spot the Defect)
> *Time: 4 Mins | Bloom: Analyze*

**Prompt:**  
Find and circle the **single syntax or concurrency bug** in this component:
```swift
struct UserProfileView: View {
    @State var name: String = "Taylor"
    
    var body: some View {
        Button("Reset") {
            self.resetName()
        }
    }
    
    func resetName() {
        name = "Guest" // <- Is this mutating allowed on a struct View?
    }
}
```
- **Correction:** [Rewrite `resetName` or state modification inline].

---

## Day 4 (Thursday): Visual Diagram Tracing
> *Time: 4 Mins | Bloom: Analyze*

**Prompt:**  
Given the following state transition flow:
`User Tap Button` $\rightarrow$ `State Flag Toggled` $\rightarrow$ `???` $\rightarrow$ `UI View Repainted`
- **Question:** What internal engine step occurs at `???`? *(Hint: View Tree Diffing)*.

---

## Day 5 (Friday): Creative Synthesis & Bridge Forward
> *Time: 5 Mins | Bloom: Evaluate / Create*

**Prompt:**  
"If you had to design a 1-sentence warning label to put on mutable global variables in a multi-threaded codebase, what would it say?"

---

## Teacher Answer Key & Scoring Guide
- **Monday:** Shared memory without synchronization causes overlapping writes (data races). Actors queue requests in an isolated mailbox.
- **Tuesday:** The spawned `Task` executes asynchronously and may not finish before `return total` executes.
- **Wednesday:** `resetName()` mutates `name` on `self` struct; in SwiftUI, mutating `@State` is valid because the property wrapper stores value externally on heap, but function should be private or state mutated directly in button action.
- **Thursday:** The SwiftUI dependency graph computes the structural diff between Old View and New View trees.
- **Friday:** Open rubric: Award credit for clear mention of non-determinism, crashes, or data corruption.
