When intermixing text and math, some people use \mbox to box the text-related stuff. The reason being that \mbox necessarily switches to text mode. So, if you have math content within \mbox, you need to explicitly restate its use. Here's a short example (causing a Missing $ inserted error):
\documentclass{article}
\begin{document}
\[
f(x)=ax^2+bx+c, \mbox{where x\geq 0}
\]
\end{document}
The symbol \geq requires math mode. Moreover, the spacing is off if the math content is not set in math mode (but that's typographic in nature).
This is error is fixed by using something like \mbox{where $x\geq 0$}. Better yet, the amsmath package provides \text which scales the text to the appropriate font size based on its context while \mbox does not.
Code readability is encouraged, which is sometimes synonymous with leaving white space within your code. In the following elementary example, however, leaving (too much) white space causes an error (Missing $ inserted):
\documentclass{article}
\begin{document}
\[
f(x)=ax^2+bx+c
\]
\end{document}
(Sure, any one blank line removed in the above would also cause the problem. But it seems more hidden due to a symmetric blank line around the equation.)
This can be avoided by either removing the blank lines, or introducing comment characters %.
When typesetting regular delimiters, there is no need to match the pairs. For example, you can have expressions like (a,b] or even |a,b. However, when using extensible delimiters you need to define a pair using \left and \right. If you want to only use a single extensible delimiter, then you still have to define a paired delimiter using ., as in the following example:
\documentclass{article}
\begin{document}
\[
f(x)=\left\{\begin{array}{@{}ll}
ax^2+bx+c, & x<0 \\
dx^2+ex+f, & x\geq 0
\end{array}
\]
\end{document}
In the above example, even though no right delimiter is needed, it has to be specified using \right..
On that note, the following is also a common mistake leading to errors when delimiting using { } (as in the above example - forgetting to escape {):
\documentclass{article}
\begin{document}
\[
f(x)=\left{\begin{array}{@{}ll}
ax^2+bx+c, & x<0 \\
dx^2+ex+f, & x\geq 0
\end{array}\right.
\]
\end{document}
The correct usage is \left\{.
Or, if you plan on using a notation like ]a,b[ (for whatever reason) and you want extensible delimiters, using \right] and then \left[ just because the brackets face outward seems logical, but doesn't work:
\documentclass{article}
\begin{document}
\[
f(x)=\right]a,\frac{b}{c}\left[
\]
\end{document}
Left delimiters use \left and right delimiters \right, regardless of the delimiter orientation.
Taken from the UK TeX FAQ entry "No line here to end":
It is definitely intuitive to use \\ to cause a line break. And, this works in some cases. However, in other cases, LaTeX complains about the fact that There's no line here to end. The proposed complication is a purely unexpected line break on LaTeX's end.
\documentclass{article}
\begin{document}
\begin{description}
\item[Very long label] \\
Text...
\end{description}
\end{document}
In the above example, the proposed quick-fix solution is to modify the line break \\ to \hspace*{\fill} \\.
Here is another example:
\begin{center}
First (heading) line\\
\\
body of the centred text...
\end{center}
A solution is provided by modifying the double line breaks \\ into a single line break with an optional length skip \\[\baselineskip].
You are learning how to write macros or your own commands and try something like:
\documentclass{article}
\newcommand{\i}{$\iota$}% My macro: \i -> \iota
\begin{document}
This is \verb!\i!:~\i.
\end{document}
only to see LaTeX complain Command \i already defined. But you never defined it in any other way, how can it be defined already?! The reason is that the document class itself can define certain commands, just like any package that is loaded can define its own macros (and environments). Moreover, TeX also defines some macros by default (around 900 or so). Specific to this case, it is possible to see what \i was defined as previously and how to correct for this new definition using
\documentclass{article}
\begin{document}
This is \verb!\i!:~\i. \par
\renewcommand{\i}{$\iota$}% My macro: \i -> \iota
This is \verb!\i!:~\i.
\end{document}
or one can use \show\i and inspect the .log file to see the "formal definition."
Another solution, provided by LaTeX2e, is to use \providecommand rather than \newcommand or \renewcommand, since it has a built-in existence check. Or, one can use TeX's \def command which has a slightly different interface. However, use these with caution, since commands defined by packages or classes have specific meaning and redefinition without the knowledge of it could have disastrous consequences.
You find a snippet of LaTeX code online and wrap it into a minimal document:
\documentclass{article}
\newcommand{\my@macro}[1]{-#1-}% This is magic
\begin{document}
\my@macro{hi}
\end{document}
However, LaTeX is not happy and complains about Missing \begin{document}. Obviously it's there... so what's the problem? Well, the @ symbol is a reserved when it comes to macro definitions and can't be used without some precaution.
The category code for @ needs to be changed in order for it to be used in a macro definition. Using \makeatletter will "make @ have 'letter'/11 as a category code" so that it can be used. Usually, it is accompanied by a \makeatother counterpart, which "makes @ have 'other'/12 as a category code".
You wish to define a command that does some formatting and decide to define a similarly-named environment that does the same thing, perhaps for the sake of convenience:
\documentclass{article}
\newcommand{\dosomething}[1]{\textbf{#1}}% Make argument bold
\newenvironment{dosomething}{\bfseries}{}% Make contents bold
\begin{document}
\dosomething{test}
\end{document}
LaTeX complains that Command \dosomething already defined at l.3 \newenvironment{dosomething}{\bfseries}{} (line 3) even though you defined \dosomething only once (in line 2).
The problem here is that when one uses \newcommand{myenv}{<beg env>}{<end env>}, LaTeX defines two commands \myenv and \endmyenv, respectively using the <beg env> and <end env> definition. To correct for this, use unique names for commands and environments, even if they perform very similar tasks. For example, in the above case, define the command \boldcmd and environment boldenv, say.
You start playing around with graphics and would like to include a picture using the graphicx package:
\documentclass{article}
\begin{document}
\usepackage{graphicx}% http://ctan.org/pkg/graphicx
\includegraphics{tiger}% Rooooaaaarrrrr!!!!!
\end{document}
but LaTeX complains that "Can be used only in preamble." This is not because of the use of \includegraphics (which is correct), but the required/included package (graphicx). The document structure requires certain "things" to be used only in certain places. In this case, you cannot load a package inside the document environment.
Place \usepackage{graphicx} between \documentclass{article} and \begin{document} - the document preamble.
You're familiar with passing arguments to macros in the form

\textbf{Here is some \textit{text}.}
Here \textit is passed as an argument to \textbf. However, you attempt to do the same with so-called verbatim content:
\documentclass{article}
\begin{document}
\textbf{Here is some \verb|verbatim text|.}
\end{document}
and receive the error "\verb illegal in command argument."
\verb and friends are delicate and should be handled with care. It deals with the advanced topic of category codes and is perhaps best described in the UK TeX FAQ entry Why doesn’t verbatim work within …?, together with appropriate solutions/alternatives. Most notably asking yourself the question whether using verbatim is actually necessary.
Someone advised you to use amsmath's align environment after reading \eqnarray vs \align and requests a duplication of the Taylor expansion of \sqrt{1-x}:

Ambitious in your attempt, you try:
\documentclass{article}
\usepackage{amsmath}% http://ctan.org/pkg/amsmath
\begin{document}
\begin{align*}
\sqrt{1+x} = 1 + x\left(\tfrac{1}{2} - \tfrac{1}{8}x + \tfrac{1}{16}x^2
&- \tfrac{5}{128}x^3 \cdots \\
&+ \tfrac{(-1)^i(2i)!}{(1-2i)(i!)^2(4i)}x^{i-1}\cdots\right)
\end{align*}
\end{document}
(La)TeX spits out an error Extra }, or forgotten \right.
\left and \right are delimiter counterparts and should always appear together and in the same (nested) group in math mode. In the above example, \left and \right are in different groups, not only spanning the align columns, but also rows. In instances like these, its much more convenient to use the separable \Bigl and \Bigr delimiter extenders. Alternatives also include using \vphantom to scale the separate groups vertically to the maximum size while using the null delimiters \right. and \left. where needed. See \left/\right across multiline equation.
errorcontextlinesis very important. – Marco Daniel Dec 30 '11 at 10:53