Once you understand short-circuit evaluation, it opens up certain coding tricks. The line "[operation] or [error condition]" will attempt the operation on the left. If it succeeds, the program continues on the next line, ignoring the part about the error condition. If it fails, the error condition will execute instead. This might be something like "open file or die". Likewise, "[operation] and [success condition]" wi…
This is commonly seen in Perl and PHP with stuff like launchMissiles() or die('failure');
That code is identical to:
launchMissiles() || die('failure');