I need to find a kernel and image of a linear map on a polynomial. And also have to solution but I don't understand the following things: why are $X$ and $X^2$ the span of the kernel? And how is the image every Rational number?
Given question and solution
Exercise 2: $T: P_3 \to \Bbb R$, $T:P(x) \mapsto P(0)$. Determine $\operatorname{Im}(T)$ and $\ker(T)$.
Solution: \begin{align} \ker(T) &= \{P(x) \in P_3 \mid P(0) = 0 \} \\ & = \{P(x) = a + bx + cx^2 \mid P(0) = 0 = a\} \\ & = \{P(x) = bx + cx^2 \mid b,c \in \Bbb R\} \\ & = S[x,x^2]. \end{align} $$ \operatorname{im}(T) = \{r \mid r = P(0) \text{ for } P(x) \in P_3\} = \Bbb R. $$
To answer each of your questions separately:
The fact that $\{P(x) = bx + cx^2 \mid b,c \in \Bbb R\}$ (as in the last line of the derivation) is equal to the span of $x$ and $x^2$ is a direct consequence of the definition of the "span". I recommend that you review the defintion of $S[v_1,\dots,v_n]$.
Note that $\Bbb R$ here means the real numbers rather than the rational numbers. The rational numbers are instead denoted by $\Bbb Q$... for quational.
Consider the following argument: for any $r \in \Bbb R$, $p(x) = 0x^2 + 0x + r$ is a polynomial for which $T(p) = r$. So indeed, every real number is an element of the image.