BDU LaTeX Practical 9 : Creating tables · caption · label · referencing

LaTeX Practical 9 – Blog Post

📘 LaTeX Practical 9

Creating tables · caption · label · referencing
❓ Question 9: Create a table with five rows and four columns in LATEX, including caption and label, and reference the table in the text.

⌨️ LaTeX Source Code

\documentclass[12pt]{article} \title{Tables in \LaTeX} \author{ARO Study Circle} \date{\today} \begin{document} \maketitle \section{Table Example} Table \ref{tab:students} shows student information. \begin{table}[htbp] \centering \caption{Student Information} \label{tab:students} \begin{tabular}{|c|c|c|c|} \hline Roll No. & Name & Course & Mark \\ \hline 1 & Abc & Mathematics & 85 \\ \hline 2 & Def & Physics & 78 \\ \hline 3 & Ghi & Computer Science & 90 \\ \hline 4 & Jkl & Statistics & 82 \\ \hline \end{tabular} \end{table} The table is referenced using the \ref{ } command. \end{document}

📖 Explanation of Commands

  • table environment creates a floating table.
  • tabular environment creates rows and columns.
  • Four c specifications create four columns with center aligned.
  • & symbol separates columns.
  • \\ command ends a row.
  • \hline creates horizontal lines.
  • \caption{} provides the table caption.
  • \label{} gives the table a reference name.
  • \ref{} refers to the table number.
  • This example contains exactly five rows and four columns, including the header row.

📄 Compiled PDF Output

Tables in LaTeX
ARO Study Circle
August 21, 2026
1 Table Example

Table 1 shows student information.

Roll No. Name Course Mark
1 Abc Mathematics 85
2 Def Physics 78
3 Ghi Computer Science 90
4 Jkl Statistics 82
Table 1: Student Information

The table is referenced using the \ref command.

Post a Comment

0 Comments