O'Reilly logo

LaTeX Beginners Guide by Stefan Kottwitz

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Time for action – titling your document

We will take the first example and insert some commands that will produce a nice-looking title.

  1. Type the following code in the editor; modify the previous example if you like:
    \documentclass[a4paper,11pt]{article}
    \begin{document}
    \title{Example 2}
    \author{My name}
    \date{January 5, 2011}
    \maketitle
    \section{What's this?}
    This is our second document. It contains a title and a section with text.
    \end{document}
  2. Click the Typeset button.
  3. View the output:
    Time for action – titling your document

What just happened?

In the first chapter, we talked about logical formatting. First, let's look at this example from that point of view. We told LaTeX that:

  • Our document ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required