First Document
Table of Contents
Creating File
Adding Content
\documentclass{article}to define the document class we want to use. In this case, it is "article". Later we will also come to know about other document classes such as "report" or "book". In order to compile a LaTeX document, we have to tell the interpreter where the document starts and where it ends. For that purpose, we have to add the environment document in the following way:
\begin{document} \end{document}If we compile our document now, we will receive an error message. This happens because LaTeX does not allow the creation of empty documents without any content. Therefore, we will add the line Hello World! between these two inserted lines. Our first full documents look now as follows:
\documentclass{article} \begin{document} Hellow World! \end{document}When we compile this code we can empty the page with the page number at the bottom and the text "Hello World!" in the first line.
Adding Packages
\usepackage{blindtext}It includes the command \blindtext that you can use within your text to create a simple blind text that is commonly used to test the layout of a document. You can now adjust your file according to the following code to see the outcome:
\documentclass{article} \usepackage{blindtext} \begin{document} \blindtext \end{document}
This page contains 540 words and 3261 characters.
Last modified: 2022-10-01 18:34:20 by mustafa