[Tex/LaTex] Despite using backslash dollar sign, error persists

errorsmath-modesymbols

\documentclass[a4paper,12pt]{article}
\begin{document}
\title{Kubuntu Setup}

Don't forget your architecture is not i386, but x86_64.  Better to use {\tt  \$(uname -i)} instead of manually specifying this

\end{document}

Gives:

! Missing $ inserted.
$ l.11 …et your architecture is not i386, but x86_
64. Better to use
{\tt …

?

Best Answer

The problem is the underscore. Use x86\textunderscore 64 or x86\_64.

\documentclass[a4paper,12pt]{article}
\begin{document}
\title{Kubuntu Setup}

Don't forget your architecture is not i386, but x86\textunderscore 64.  Better to use \texttt{\$(uname -i)} instead of manually specifying this

\end{document}

I also change tt to \texttt. Alternative you can use \ttfamily. For more information about this topic read l2tabu

Quoted from l2tabu:

Why not use obsolete commands? Obsolete commands do not support LATeX2ε’s new font selection scheme, or NFSS. {\bf foo}, for example, resets all font attributes which had been set earlier before it prints foo in bold face. This is why you cannot simply define a bold-italics style by {\it \bf Test} only. (This definition will produce: Test.) On the other hand, the new commands \textbf{\textit{Test}} will behave as expected producing: Test. Apart from that, with the former commands there is no ‘italic correction’, cf. for instance halfhearted ({\it half}hearted) to halfhearted (\textit{half}hearted).