TOCTOU occurs when a condition changes after a program checks it but before the program acts on it. An attacker may exploit that gap—for example, by replacing a validated file with a malicious one. section 12.3.2
The last ticket
A ticket appears available when you check, but someone else buys it before you complete your purchase. The condition changed between checking and acting. section 12.3.2
