$$\begin{pmatrix}1\\2\\0\end{pmatrix} = \frac12\begin{pmatrix}1\\0\\0\end{pmatrix}+\frac12\begin{pmatrix}1\\4\\0\end{pmatrix}+0\begin{pmatrix}0\\0\\1\end{pmatrix}$$
Applying the function $l$ and using as above the properties for linear maps:

While for the basis $\mathcal{B}$ you can see that $(0,2,4)^T = 2(0,2,1)^T$ and for
$$\begin{pmatrix}1\\4\\1\end{pmatrix}=0\cdot\begin{pmatrix}1\\0\\0\end{pmatrix}+\begin{pmatrix}1\\4\\0\end{pmatrix}+\begin{pmatrix}0\\0\\1\end{pmatrix}$$