Suppose that $\{ \vec{v}_1 ... \vec{v}_n \}$ is a subspace of $V$. Let $W$ be a proper subspace of $V$. Prove that there exists a linear transformation $f:V\rightarrow \mathbb{R}$ such that $f(\vec{w})=0\ \forall \vec{w} \in W$, but $\exists \vec{v} \in V$ such that $f(\vec{v}) = 1$.
The proof I came up with involves defining a basis for $W$ and then extending it to be a basis for $V$. Then I said to define a function, $f$, where $f(\vec{w}) = 0$, for each of the basis vectors of $W$ and $f(\vec{v}) = 1$ for the other basis vectors of $V$.
I am unsure if I can assume that this $f$ is linear. It seems intuitive to me that it is since you could define it such that it follows addition and scalar multiplication rules, but is this something I need to prove or lay out for this definition? If I have to elaborate on this function more, how would I do it to demonstrate that it obeys addition?
There's no problem with your approach, because, for any basis $e_1,\ldots,e_n$ of $V$ and any scalars $\lambda_1,\ldots,\lambda_n$, there's one and only one linear map $f\colon V\longrightarrow\mathbb R$ such that$$(\forall i\in\{1,2,\ldots,n\}):f(e_i)=\lambda_i.$$