First Weierstrass theorems about boundedness of a function within closed, bounded interval. If $I=[a,b]$ is closed, bounded interval and $f:I \rightarrow R$ is a continuous function at the interval $I$, then $f$ is bounded at this interval.
Proof: 

$I=[a,b]$ - bounded, closed interval. $f:I \rightarrow R, -$
  continuous function. Suppose that $f$ is not bounded on $I$. Then
  $\forall n\in N \ \ \exists x_n \in I:|f(x_n)> n|.$

In this case does $x_n$ is meant to be a sequence or a term in a sequence? Let' s say there is a function $f(x)=x^2$ how would this make for a sequence within an interval [0,4]? Is the sequence simply formed of the values that function takes at the given interval?

Take a sequence $(x_n)_{n\in N}$. Because the interval I is bounded so
  is this sequence ( every term for the sequence lies within I). Then the sequence $x_n$ is a bounded sequence, and from Bolzano-Weierstrass theorem it follows that there exists a subsequence $(x_{n_k})_{k \in N}$, that converges to $L$, t.i., $lim_{k \to \infty}x_{n_k}=L$. 
  Because I is closed interval, the terms of the subsequence also lie within the I so $L \in I.$

To me it is not that obvious why $L \in I$? 

$f:I \rightarrow R$ is a continuous function, so $f(x_{n_k})$
   converges to $f(L)$. As $f(x_{n_k})$ converges, it is bounded.
  This forms a contradiction, because $|f(x_{n_k})|>n_k \ge k \forall k\in N$.

I don't understand this at all, I know that previously the proof states, that if $f$ is not bounded then $|f(x_n)>n|.$ But I assumed that it is simly some natural number, here it seems, that it is somehow related to the indexes of the sequence and subsequence. Can someone shed a light on this?
 A: It's a sequence. In this case $x_n$ is meant to be a term in the sequence. As noted by copper.hat, each $x_n$ is defined to be such that $|f(x_1)| > 1, |f(x_2)| > 2, |f(x_3)| > 3, ...$ This is a proof by contradiction, so you can't actually do this for a function like $f(x) = x^2$. 
How to create the sequence? If you wanted to imagine that instead $x^2$ was some unbounded function in $[0, 4]$, let's say it shot up to infinity at $x = 4$, then that means as we approach $x = 4$ the value of $f(x)$ gets larger and larger. We could say "ah this function will shoot up!" So at some point $f(x) > 1$; suppose you look at the graph and see this occurs at, say just for example, $x = 2$. Then set $x_1 = 2$. Now at some point, $f(x) > 2$; we could look at the graph and see, for example, it occurs at $x = 2.5$. Then $x_2 = 2.5$. Since we're assuming the function is unbounded, we know for each $n$, there exists a $x_n$ such that $|f(x_n)| > n$. So we can keep going with this process. 
Convergence in the interval. You should try to think about the fact that $L$ is in the interval more intuitively. If that doesn't help, try to supply your own proof. One can try by contradiction: 
Suppose $\{x_n\}$ is a sequence where $a \le x_n \le b$ for all $n \in \mathbb{N}$, and $lim_{n \to \infty} x_n = L$, but for some reason $b < L$. In this case, let $\delta = L - b$. Hence $\delta < |L - x_n|$ for all $x_n$.
Since $\{x_n\} \rightarrow L$, we know for every $\epsilon > 0$ there exists a $n \in \mathbb{N}$ such that $|L - x_n| < \epsilon$. However, set $\epsilon = \delta$. Then there's no $x_n$ which can satisfy this definition, because $|L - x_n| > \delta$.
Last Step. 
Your confusion is on par though: they said at the beginning that $f$ is unbounded, and they characterized this by creating a sequence $\{x_n\}$ such that $|f(x_n)| > n$; so what gives? 
Note the fact that $f(x)$ is unbounded implies that $f(x_n)$ does not converge, and for any subsequence $\{x_{n_k}\}$, $f(x_{n_k})$ also doesn't converge. 
But in the last step, they ended up showing is that 1) there DOES exist a subsequence which converges to a value $L \in I$ and (2) because $f(x)$ is continuous, $f(x_{n_k}) \rightarrow f(L)$. This is what we wanted, because we assumed the opposite of the theorem (which is wrong), so we eventually wanted to prove something wrong; hence, this proves the theorem.
Subsequence. Note: if your confusion is on the definition of the subsequence, you can think of a subsequence $\{x_{n_k}\}$ as a subset of $\{x_n\}$. That is, someone created $\{x_{n_k}\}$ by going through $\{x_n\}$ and picking out an infinite number of elements in that sequence to create another one.
