(This is in the set of real numbers) $g(x)=\sin x$ prove this is either surjective(onto), injective(one to one), or both
i understand that $f(x) = x^2$ is not injective because $f(x)f=f(-x)$ and we would have to set a restriction on the set of real numbers to make it injective. The textbook does not explain injective or surjective clearly. If someone could maybe explain injective and surjective, and how to prove them for a given function, that would be fantastic.
(discrete mathematics)
Note that $f(x)=\sin(x)$, viewed as a function $f:\mathbb{R}\to\mathbb{R}$, is neither injective nor surjective. It can't be injective because $\sin(0)=\sin(2\pi)=0$. It can't be surjective because $-1\leq \sin(x)\leq 1$, so for instance $\sin(x)=2$ does not have a solution.