Touching a ghost kills it.
For a challenge, see how long you can survive without touching any of the ghosts.