How to beat Must Escape the Haunted House (Cool Math Games)

Escape in record time.