Let $f:[0,1]\to\mathbb R^n$ such that $f(t)=ty+(1-t)x$ for some $x,y \in \mathbb R^n$. Prove that $f$ is continuous.
I know a definition that A function $f\colon X \rightarrow Y$ between two topological spaces $X$ and $Y$ is continuous if for every open set $V \subset Y$, the inverse image $f^{-1}(V) = \{x \in X \; | \; f(x) \in V \}$ is an open subset of $X.$
However I don't know how to apply the definition to solve the problem. Any help would be appreciated.