The book follows a form of logic called "Catch-22." It's a paradoxical law that means you're circumstantially screwed – no matter what choice you make. Since the publication of the novel, the term "Catch-22" has been used to describe any unsolvable logical dilemma or deadlock. The protagonist of the novel, Yossarian, often finds himself stymied by his own Catch-22: he's caught up in situations that prove life threatening, but he can't legally escape them.
The novel was originally titled Catch-18 but changed when another WWII novel with the number eighteen was published around the same time. So Heller decided on 22 because the repeated numbers parallel some repeating events in the book and describe the déjà vu type occurrences (source. So he killed two birds with one stone. Clever guy.