Tips for understanding the Pumping Lemma for Context-Free Languages
One way of looking at the pumping lemma is in terms of the pumping game, a two-player game parametrized by an infinite language $L$. The two players are the Prover and Challenger, and the game goes as follows:


Prover picks an integer $n$.
Challenger picks a word $w \in L$ of length at least $n$.
Prover chooses a decomposition $w = xyz$ such that $|xy| \leq n$ and $|y| \ge 1$.
Challenger chooses an integer $i$.
If $xy^iz \in L$ then Prover wins, otherwise Challenger wins.


The pumping lemma states that:


  If $L$ is regular then Prover has a winning strategy.


The pumping lemma is often used in the contrapositive:


  If Challenger has a winning strategy then $L$ is not regular.




Here is an example: we will show that Challenger has a winning strategy for the language $L = \{a^nb^n : n \geq 0\}$.

In response to Prover's choice of $n$, Challenger chooses the word $w = a^n b^n$. In response to Prover's choice of a decomposition $w = xyz$ such that $|xy| \leq n$ and $|y| \geq 1$, Challenger chooses $i=0$. Then $xy^iz = a^{n-|y|}b^n \notin L$, and so Challenger wins.