Consider a vector-valued function $f: [0,1]^n\rightarrow[0,1]^n$. Write $f(x)=\{f_1(x), ..., f_n(x)\}$ with $x\in[0,1]^n$, where the $f_i: [0,1]^n\rightarrow[0,1]$ are continuous functions with the following properties:

1) $f_i(\{x_1, x_2, ..., x_n\})=0$ if $x_i=0$.

2) $f_i(\{x_1, x_2, ..., x_n\})=1$ if $x_i=1$.

Fix $p\in[0,1]^n$. I want to prove that there exists a solution $x\in[0,1]^n$, such that $f(x)=p$.

If feel that this should be true, since by the intermediate value theorem, we know that for fixed $x_2$, ..., $x_n$ we can find $x_1$ such that $f_1(\{x_1, x_2, ..., x_n\})=p_1$ (and similarly for $f_2$ we can find an $x_2$ if we fix the other $x_i$'s).

Any help is appreciated.