0

I need your help please on creating a table as shown in the following picture. I can create a basic table but I am having problem with the subcells in the middle of it.

I will fill this table with words only if this matters.

Can you please show me how to do it?!

Thanks enter image description here

1 Answer 1

4

Here is your favorite table. multirow and multicolumn are your best pets.

\documentclass[a4paper]{article}
\usepackage{multirow}
\begin{document}

\begin{table}
\begin{tabular}{|l|l|l|l|l|}
\hline
Hi                & \multicolumn{4}{l|}{}                             \\ \hline
                  & \multicolumn{4}{l|}{There}                        \\ \hline
                  & \multicolumn{2}{l|}{}        & I'm        &       \\ \hline
                  & \multicolumn{4}{l|}{}                             \\ \hline
\multirow{2}{*}{} & A nice       & \multicolumn{2}{l|}{Small} &       \\ \cline{2-5} 
                  &              & \multicolumn{2}{l|}{}      & Table \\ \hline
                  & \multicolumn{4}{l|}{}                             \\ \hline
\end{tabular}
\end{table}

\end{document}

enter image description here

2
  • Than you so much AboAmmar, I have one thing please. I have long sentences in the cells, the words cross the page and I don't know how to make them contained in the cell. In other words, is there any way to make the table forced to be contained in the center of the page. Thanks!
    – Ali A.
    Commented Dec 27, 2018 at 13:04
  • I encourage you to post another question for this problem, preferably adding your real text and the exact requirements. That's, specify which columns would contain long sentences and if you prefer the table occupy whole textwidth, etc.
    – AboAmmar
    Commented Dec 27, 2018 at 13:28

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .