4 March 2022

Housekeeping

while

Indefinite looping

This is Python's indefinite loop. Its general form is


while predicate:
    block

You can think of while as a "sticky if," which keeps executing until the predicate is falsy.

Quick Review: Falsiness and Truthiness

Stephen Colbert, creator of truthiness

Nagging

Stochastic Simulation: A Coin Experiment