Please check my linear algebra solution. Let $\mathbb{P}_n[\mathbb{R}]$ denote the space of polynomials with real coefficients with degree $\leq n$ along with zero polynomial. Consider the linear transformation $ D:\mathbb{P}_n[\mathbb{R}] \to \mathbb{P}_{n-1}[\mathbb{R}]$ defined by $D(f)=f'$ and $T:\mathbb{P}_n[\mathbb{R}] \to \mathbb{P}_{n+1}[\mathbb{R}]$ defined by $T(f)=xf$. If $A=DT-TD:\mathbb{P}_n[\mathbb{R}] \to \mathbb{P}_{n}[\mathbb{R}]$, find $\ker(A)$ and $\dim(\mathbb{P}_n[\mathbb{R}]/\ker(A)).$
My attempt:
\begin{align*}
\ker(A) &=  \{  f\in \mathbb{P}_n[\mathbb{R} ]:A(f)=0   \}\\
&= \{ f\in \mathbb{P}_n[\mathbb{R}] : (DT-TD)(f)=0   \}\\
&= \{ f\in \mathbb{P}_n[\mathbb{R}] : (DT)(f)-(TD)(f)=0   \}\\
&= \{ f\in \mathbb{P}_n[\mathbb{R}] : (D)(T f)-(T)(D f)=0   \}\\
&= \{ f\in \mathbb{P}_n[\mathbb{R}] : (D)(x f)-(T)(f')=0   \}\\
&= \{ f\in \mathbb{P}_n[\mathbb{R}] : (x f'+f)-(xf')=0   \}\\
&= \{ f\in \mathbb{P}_n[\mathbb{R}] :   f =0   \}\\[2ex]
&\implies \ker(A)=\{0\}\\
&\implies \dim(\ker(A))=0
\end{align*}
So $\dim(\mathbb{P}_n[\mathbb{R}] /\ker(A))= \dim(\mathbb{P}_n[\mathbb{R}])-\dim(\ker(A)) =n+1-0=n+1$.
 A: Your $\ker(A)=\{0\}$ is correct where linearity allows you to do such operations as $(DT-TD)(f)=(DT)(f)-(TD)(f)$. (Differentiation is linear, i.e., $D(f+g)=(Df)+(Dg)$, and $D(af)=a(Df)$ where $f$ and $g$ are functions, and $a$ is a constant, and the same goes for the linear map $T$.)
Then note $\mathbb{P}_n[\mathbb{R}]/\ker(A)\cong\mathbb{P}_n[\mathbb{R}]$, since $\ker(A)=\{0\}$. Hence the kernel consists of only one point, and a space consisting of one point has dimension $0$. So
$$\dim(\mathbb{P}_n[\mathbb{R}]/\ker(A))= \dim(\mathbb{P}_n[\mathbb{R}]/\{0\})=\dim(\mathbb{P}_n[\mathbb{R}]) =n+1,$$
since $\mathbb{P}_n[\mathbb{R}]$ has a basis $B_{\mathbb{P}_n[\mathbb{R}]}=\{1,\,x,\,x^2,\dots,\,x^n\}$ consisting of $n+1$ elements.
Note your answer for the dimension is also correct, and uses the Rank-Nullity Theorem which relates the dimensions of the kernel and image to that of the space in question:
$$\dim(\ker(A))+\dim(\operatorname{im} (A))=\dim(\mathbb{P}_{n}[\mathbb{R}]).$$ 
The number $\dim(\operatorname{im}(A))$ is called the rank of $A$ and written as $\operatorname{rank}(A)$, where $\operatorname{im}(A)\cong \mathbb{P}_n[\mathbb{R}]/\ker(A)$, and the number $\dim(\ker(A))$ is called the nullity of $A$, written $\operatorname{null}(A)$.
