# If $A=\{-1,0,1\}$ and $f:A\rightarrow A$ is defined as $f(x)=x^2$, then what type of function is $f$ ?

$\begin{array}{1 1} 1-1 \;function \\ onto\;function \\ both 1-1\;and\;onto \\ neither \;1-1\;nor\;onto \end{array}$

$f(-1)=(-1)^2=1,\:\:f(0)=0\:\:and\:\:f(1)=1$
since $f(-1)=f(1)$ $f$ is not 1-1.
Also since $-1\in A$ is not an image of any of the element in A,$f$ is not onto