
I don't understand the step underlined in green.
I understand that for any $n$ , $|f(x_n)-f(y_n)|\geq \varepsilon$ where $x_n, y_n$ satisfy the conditions given regarding a function being not uniformly continuous. However if say $x_n=\frac{1}{2n}, y_n=\frac{1}{3n} $ then $|x_n-y_n|=\frac{1}{6n}$ and $|f(\frac{1}{2n})-f(\frac{1}{3n})|\geq \varepsilon$
so if we take $n=1$ , $|f(\frac{1}{2})-f(\frac{1}{3})|\geq \varepsilon$
but what if $|x_{k_n}-y_{k_n}|\geq\frac{1}{n}?$
Your problem stems from the somewhat unfortunate circumstance that the author denotes a subsequence of the sequence $(x_n)_{n\geq1}$ by $(x_{k_n})$ instead of $(x_{n_k})_{k\geq1}$.
He begins with two sequences $(x_n)_{n\geq1}$, $(y_n)_{n\geq1}$ behaving badly insofar as $|f(x_n)-f(y_n)|\geq\epsilon_0$ for all $n$, even though $|x_n-y_n|\to0$ as $n\to \infty$. In order to be able to invoke the continuity of $f$ we'd like to have all $x_n$, $y_n$ near some point $\xi\in[a,b]$. Bolzano's theorem guarantees that there is some $\xi\in[a,b]$ such that "infinitely many" $x_n$, $y_n$ are in the immediate neighborhood of $\xi$. To be exact: There is a selection function $$\sigma:\quad{\mathbb N}\to{\mathbb N}, \qquad k\mapsto n_k$$ such that the "good" $x_n$, namely the selected $x_{n_k}$ $\>(k\geq1)$, actually converge to $\xi$. It is then easily seen that $$\lim_{k\to\infty} x_{n_k}=\lim_{k\to\infty} y_{n_k}=\xi\ .$$ Since $f$ is continuous at $\xi$ this implies $$\lim_{k\to\infty} \left(f\bigl(x_{n_k}\bigr)-f\bigl(y_{n_k}\bigr)\right)=f(\xi)-f(\xi)=0\ .$$ On the other hand, we have $|f(x_n)-f(y_n|\geq\epsilon_0$ for all $n$, good or bad, so that we arrive at a contradiction.