[Tex/LaTex] how to write centered plus minus 1 in inline math mode in latex

inline()math-modepdftex

I want to write y belongs to plus minus 1 but i do not know how to write it. My code is as below:

\begin{document}  
 $y\in$ +- 1
\end{document

but it is not giving centered plus minus 1.

Best Answer

Using math mode (best solution):

\documentclass{article}

\begin{document}  
 $y \pm 1$
\end{document}

If you don't want to use math mode (worst solution):

\documentclass{article}
\usepackage{textcomp}
\begin{document}  
 $y$ \textpm 1
\end{document}