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

Python Basic — 045: Re-shape process fences under light mutation centred on `Booleans, comparisons, and truthiness` [843655]

Lesson 045: Booleans, comparisons, and truthiness

Focus

This page is deliberate repetition with new literals: Basic drills Booleans, comparisons, and truthiness; spin token 383873 makes this page unlike its neighbours.

Key ideas

Example (LESSON_UID = "basic-045")

# Basic drill L045 topic-4 micro-4 pattern-3
LESSON_UID = "basic-045"
spin_a, spin_b, spin_c = 701, 592, 384

sentinel = ([] or [])
sentinel = sentinel or [11]
print(bool(sentinel), sentinel)
pick = sentinel or "fallback-45"
print("chosen", pick)

Practice

Practice 14: Enumerate three pytest markers you'd decorate if this lived in CI. Literal nudge 14.

Fingerprints