Jim Holt is a science writer whose latest book, Stop Me If You’ve Heard This, traces the history and meaning of the joke. In fact, he says all jokes were born with a Greek man named Palamedes, who apparently invented the setup of incongruity and resolution in a punch line.
Also, he says we laugh at stuff because we were once scared monkeys or something:
Wired: But your favorite explanation is a mashup of Kant and evolutionary biology, right?
Holt: V. S. Ramachandran, the brain researcher, has a theory about the origin of laughter — that when you’re in the jungle and there’s an apparent threat, the first member of the kinship group to notice that it’s not a real threat emits this stereotyped vocalization. And it’s contagious, so everyone starts laughing. That’s also the basis of the relief theory of humor, that there’s a release of the energy you had summoned up to solve some puzzle. Kant said that the essence of humor is a strained expectation dissolving into nothing.
Hmmm. Suddenly this makes a lot more sense: