Code examples from the Gray Hat Python book.