答案1
\documentclass{article}
\usepackage{multirow}
\begin{document}
\begin{tabular}{|c|c|c|c|c|}
\hline
\multirow{2}{*}{XX} & & \multicolumn{3}{c|}{} \\
\cline{3-5}
& & XXXX & XXX & XXXX \\
\hline
xxx & xxx & xx & xx & xx \\
yyy & y & yy & yy & yyy \\
zzz & zz & zz & zzzz & zz \\
\hline
\end{tabular}
\end{document}
尽管最好避免使用垂直规则,正如booktabs
\documentclass{article}
\usepackage{multirow}
\usepackage{booktabs}
\begin{document}
\begin{tabular}{ccccc}
\toprule
\multirow{2}{*}[-3pt]{XX} & \multirow{2}{*}[-3pt]{XX} & \multicolumn{3}{c}{} \\
\cmidrule{3-5}
& & XXXX & XXX & XXXX \\
\midrule
xxx & xxx & xx & xx & xx \\
yyy & y & yy & yy & yyy \\
zzz & zz & zz & zzzz & zz \\
\bottomrule
\end{tabular}
\end{document}