Example code from "Javascript: The Good Parts" by Douglas Crockford