Subversion

Subversion is the attempt to lead the audience to expect one thing and give them something else. It is often used to change a hacky joke into something more fun "You ever notice how black people walk like this, but white people like to steal people's land?" employs subversion on a hack joke.

Subversion is also used when the setup for a joke is a misdirect. "You ever notice when you're standing in a long line, and when you finally get to the front of the line Tiger Woods doesn't want sex anymore?" In this joke, the punchline subverts the rest of the joke because the audience was most likely picturing standing in line for a more boring reason, such as the bank, the pharmacy, or for an abortion.