Error: extra alignment tab has been changed to \cr
The error can be reproduced by
\documentclass{article}
\begin{document}
\begin{tabular}{c|c}
one & two & three \\
\hline
one & two
\end{tabular}
\end{document}
The problem is caused by the extra column you try to insert. The tabular environment expects two columns but three is inserted.
Not all extra alignment tab has been changed to \cr
errors are found via Google or Bing. Something as simple as defining a macro with arguments and forgetting the argument before the first \\
will reproduce the error.
Same thing with \newcommand
.
e.g.,
\def\test#1#2{$\hbox to 4cm{#1}}$}
\begin{tabular}{cccc}
Oh & \test{tested}{} & Oh & \test{Oh} \\
& \test{testing}{} & & \test{Ohh}{} \\
\end{tabular}
Hi,I had the same question and googled to this page. At last, I solved this problem by add one more c, the correct case should like below:
\documentclass{article}
\begin{document}
\begin{tabular}{c|c|c}
one & two & three \\
\hline
one & two
\end{tabular}
\end{document}