1

I want to create something like this:

enter image description here

Can someone explain how to do it?

MattAllegro
  • 6,455
  • 5
  • 45
  • 52

2 Answers2

1

See this answer too. Here's a sketch for you, using indeed multirow package:

\documentclass{article}
\usepackage{multirow}

\begin{document}
\begin{tabular}{|c|c|c|c|}
\hline
\multirow{2}{*}{1} & \multirow{2}{*}{2} & \multicolumn{2}{|c|}{3}\\
\cline{3-4}
                   &                    & 3a & 3b\\
\hline
                   &                    &    & \\
\end{tabular}
\end{document}

screenshot of output

MattAllegro
  • 6,455
  • 5
  • 45
  • 52
0

As already said in comments, the tabularray packages makes it really easy to merge cells:

\documentclass{article}
\usepackage{tabularray}

\begin{document}
\begin{tblr}{
  colspec={cccc},
  vlines,
  hlines,
}
\SetCell[r=2]{} 1 & \SetCell[r=2]{} 2 & \SetCell[c=2]{} 3\\
& & 3a & 3b\\
& & & \\
\end{tblr}
\end{document}

enter image description here