I am writing a long lex file, and getting tired of scrolling up and down. So does anyone know if there is a method that can allow me to write multiple short lex files and combine them to generate one pdf file?
Asked
Active
Viewed 60 times
1 Answers
1
Use \input{sub_file}
in your main tex file to include the latex content of the sub_file
in the main file:
Main file:
\documentclass{article}
\usepackage[utf8]{inputenc}
\begin{document}
\section{Section 1}
\input{section1}
\end{document}
Sub file {section1}:
\subsection{A subsection}
Some \LaTeX{} to fill the section

Math
- 2,399
- 2
- 20
- 22
-
Also: http://tex.stackexchange.com/questions/246/when-should-i-use-input-vs-include – MattAllegro Apr 23 '15 at 21:39