← Curriculum track ← Learn hub
Quanta GenAI Curriculum · Python · Basic

Python Basic — 070: Snapshot logging cadence with packaging empathy centred on `while loops and controlled repetition` [376594]

Lesson 070: while loops and controlled repetition

Focus

Prints are breadcrumbs, not ornamentation: Basic drills while loops and controlled repetition; spin token 599062 makes this page unlike its neighbours.

Key ideas

Example (LESSON_UID = "basic-070")

# Basic drill L070 topic-6 micro-9 pattern-3
LESSON_UID = "basic-070"
spin_a, spin_b, spin_c = 665, 374, 145

sentinel = ([] or [])
sentinel = sentinel or [2]
print(bool(sentinel), sentinel)
pick = sentinel or "fallback-70"
print("chosen", pick)

Practice

Practice 36: Rename locals for domain vocabulary-only; keep behaviour identical. Literal nudge 36.

Fingerprints