VI

Adversity

When programs execute, abnormal things may happen, either intentionally (by malicious attacks) or unintentionally (by programmer's overlook or unexpected failures in hardware). Dealing with them is perhaps one of the most complicated activities in program design. One approach to dealing with abnormalities is to be oblivious to them. This can be done by either (1) assuming that errors don't occur or (2) not caring if they occur. For the purpose of focusing on specific constraints without distractions, obliviousness is the style followed in this book – except in the next five styles. The next five chapters – Constructivist, Tantrum, Passive Aggressive, Declared Intentions and Quarantine – reect five different approaches to dealing ...

Get Exercises in Programming Style now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.