Finding the basis of a subset of polynomials 
Let $W$ be a subspace of the polynomials with maximum degree of $3$ and $p(1) = p(2) = 0$. Find the basis and the dimension of the subspace. The field is the real numbers.

My attempt:
My first thought is that it is the usual basis of $\mathbb{P}_3 = \{1, x, x^2, x^3\}$.  However, on second thought, is it a trick question? We will never have $p(1) = p(2)$, will we? So would the basis be the empty set and the dimension be $0$?
 A: Note that $p(x)=ax^3+bx^2+cx+d$ satisfies $p(1)=p(2)=0$ if and only if
\begin{array}{rcrcrcrcrcrcrc}
a&+&b&+&c&+&d&=&0 \\
8\,a&+&4\,b&+&2\,c&+&d&=&0
\end{array}
But
$$
\DeclareMathOperator{rref}{rref}\rref
\begin{bmatrix}
1&1&1&1&0\\8&4&2&1&0
\end{bmatrix}
=
\begin{bmatrix}
1&0&-1/2&-3/4&0\\ 0&1&3/2&7/4&0
\end{bmatrix}
$$
so 
\begin{align*}
p(x)
&= ax^3+bx^2+cx+d \\
&= \left(\frac{1}{2}c+\frac{3}{4}d\right)x^3+\left(-\frac{3}{2}c-\frac{7}{4}d\right)x^2+cx+d \\
&= c\left(\frac{1}{2}x^3-\frac{3}{2}x^2+x\right)+d\left(\frac{3}{4}x^3-\frac{7}{4}x^2+1\right)
\end{align*}
This proves that 
$$
\left\{\frac{1}{2}x^3-\frac{3}{2}x^2+x,\frac{3}{4}x^3-\frac{7}{4}x^2+1\right\}
$$
form a basis for $W$.
A: You need a basis that incorporates $p(1)=p(2)=0$ while still having polynomials of degree three. So you won't have a constant term, and you need some polynomials like $(x-1)(x-2)$ in your basis set. Then because you need degree three polynomials, maybe include $x(x-1)(x-2)$. So our set could be 
$$S=\{(x-1)(x-2),x(x-1)(x-2)\}$$
can anybody confirm this might be right? I'm not that confident, I'm just throwing out ideas for you.
edit: another answer is basically the same as this, so I'll assume that this is right and say, there you go!
