I'm trying to list some sections inside a chapter (let's say sections 2.1, 2.2, 2.3, 2.4 and 2.5), and in the section 2.2 I show 4 tables, the problem is that the titles of the sections 2.3, 2.4 and 2.5 are being shown before the last table that is in the section 2.2
Can someone tell me how can I fix this?
This is my code:
\chapter{Resolución de modelos}
\section{Utilice el método gráfico para encontrar soluciones al modelo ¿Es posible encontrar el óptimo?}
\section{Resuelva el problema usando el método Simplex}
# HERE ARE THE 4 TABLES
\section{Explique cada una de las bases encontradas durante la realización del algoritmo Simplex}
\section{¿Existen soluciones alternativas a la solución encontrada? Explique}
And this is the output:
All the tables should be after the title of the section 2.2 and before the title of the section 2.3
EDIT:
Here's an example of the code I'm using to produce the tables:
\begin{table}[ht]
\centering
\begin{adjustbox}{width={\textwidth}, totalheight={\textheight}, keepaspectratio}
\begin{tabular}{c c c c c c c c c c c}
\hline
# CONTENT
[1ex]
\hline
\\ [0.5ex]
# CONTENT
[1ex]
\hline
\end{tabular}
\end{adjustbox}
\caption{Iteración \#5}
\end{table}

tableenvironment? that, by definition, "floats". in other words, it will be placed where, according to latex's rules, the floating object fits best. we need to see the input for the table structure (you don't have to include the details of the table contents) in order to answer with certainty. this question contains useful information: How to influence the position of float environments like figure and table in LaTeX? – barbara beeton Aug 27 '16 at 23:48\documentclassand ending with\end{document}that a potential tester can cut and paste to experiment. that isn't actually necessary in this case, since this problem is a common one. since your tables are small, and you want them tpo appear exactly where you input them, it's not necessary to use thetableenvironment at all. instead, just code them withtabularand use\captionof(captionpackage needed). put them in aminipagewhen changing dimensions. – barbara beeton Aug 27 '16 at 23:59