1

The multicolumn table’s rows won’t join, picuture supplied.

enter image description here

This is what I’ve written for the table:

\begin{tabular}{|*{4}{c|}}
\hline
\multicolumn{4}{|c|}{Declension} \\ \hline
\multicolumn{2}{|c}{First} & \multicolumn{2{|c|}{Second} \\ \hline
\textit {Strong} & \textit {Weak} & \textit {Strong} & \textit {Weak} \\ \hline
\\ \hline
\end{tabular}

Why won’t the lines join up and complete the table, what have I done wrong?

Thanks in advance.

(I’m a beginner)

2
3

There was a missing }. You just have to add & in the empty line.

(Edit: considered comments of David Carlisle)

\documentclass{article}

\begin{document}
    \begin{tabular}{|*{4}{c|}}
        \hline
        \multicolumn{4}{|c|}{Declension} \\ \hline
        \multicolumn{2}{|c|}{First} & \multicolumn{2}{c|}{Second} \\ \hline
        \textit {Strong} & \textit {Weak} & \textit {Strong} & \textit {Weak} \\ \hline
        & & & \\ \hline
    \end{tabular}
\end{document}

enter image description here

1
  • \multicolumn{2}{|c}{First} & \multicolumn{2}{|c|}{Second} \\ \hline should be \multicolumn{2}{|c|}{First} & \multicolumn{2}{c|}{Second} \\ \hline although the error is more noticeable if you also add \usepackage{array} Jan 31 '17 at 23:44
2

Replace, at the end of the table,

\\ \hline \\ \hline

with

\\ \hline
&&&&\\ \hline

or

\\ \hline
    \multicolumn{4}{|c|}{}\\ \hline

depending on how many vertical lines you want in the last row.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.