5

What different effects do ending a paragraph in the following three ways have?

1.

    words words words

    words words words

2.

    words words words\\
    words words words

3.

    words words words\\

    words words words
Abijah
  • 475
  • 3
  • 11

1 Answers1

5

As I said in my comment, "The first provides a paragraph break, the second is a forced line break within a paragraph, which is not generally recommended. Since many LaTeX actions are only executed at the end of a paragraph, the seeming small difference in syntax can have a profound appearance on the output."

Here are some examples of functional differences.

\documentclass[a4paper]{article}


\begin{document}

CENTERING:

{
line 1

line 2\centering

}

\noindent versus

{
line 1\\
line 2\centering

}

\noindent\hrulefill

PARAGRAPH SPACING AND INDENTS

{\parskip 1em
line 1

line 2

}

\noindent versus

{\parskip 1em
line 1\\
line 2

}

\noindent\hrulefill

LEFT AND RIGHT SKIPS

{
line 1

line 2\leftskip 1in

}

\noindent versus

{
line 1\\
line 2\leftskip 1in

}

\end{document}

enter image description here

Note this code can be automated in a macro (note that an extra blank line is the same thing as a \par for the purposes of LaTeX):

\documentclass[a4paper]{article}
\newcommand\stencil[3]{\par\bgroup#2 line 1#1line 2#3\par\egroup}
\begin{document}
CENTERING:

\stencil{\par}{}{\centering}
\noindent versus
\stencil{\\}{}{\centering}
\noindent\hrulefill

PARAGRAPH SPACING AND INDENTS

\stencil{\par}{\parskip 1em}{}
\noindent versus
\stencil{\\}{\parskip 1em}{}

\noindent\hrulefill

LEFT AND RIGHT SKIPS

\stencil{\par}{}{\leftskip 1in}
\noindent versus
\stencil{\\}{}{\leftskip 1in}
\end{document}