Use multicolumn under multicolumn

multicolumntables

In the following table, I want to use 2 columns under D & 3 columns under F.
How to do this?

\begin{table}[]
    \centering
    \begin{tabular}{|c|cc|c|}
     \hline
      
    A    & \multicolumn{2}{c|}{B}  & C\\
     \hline
                              &  D & F & \\
      \hline
      
      \hline
    \end{tabular}
    \caption{}
    \label{tab:my_label}
\end{table}

Best Answer

enter image description here

\documentclass{article}
\begin{document}

    \begin{tabular}{|c|c|c|c|c|c|c|}
      \hline
      A    & \multicolumn{5}{c|}{B}                           & C\\
      \hline
           &  \multicolumn{2}{c|}{D} & \multicolumn{3}{c|}{F} & \\
      \hline
           & 1 & 2                   & 1 & 2 & 3              & \\
      \hline
    \end{tabular}

\end{document}
Related Question