7

How would I get rid of the date, and the numbers 1 and 2? My latex code is below. I cant post images as Im a new user, sorry!

\documentclass[10pt]{article}


\begin{document}

\title{Banana Cake}
\maketitle


\section{Ingredients}

\begin{itemize}
  \item The first item
  \item The second item
  \item The third etc
\end{itemize}

\section{Method}
\begin{enumerate}
  \item The first item
  \item The second item
  \item The third etc
\end{enumerate}



\end{document}
Stefan Kottwitz
  • 231,401
Derrick
  • 171

2 Answers2

9

Use \date{} and starred versions of section

\documentclass[10pt]{article}


\begin{document}

\title{Banana Cake}
\date{}
\maketitle


\section*{Ingredients}

\begin{itemize}
  \item The first item
  \item The second item
  \item The third etc
\end{itemize}

\section*{Method}
\begin{enumerate}
  \item The first item
  \item The second item
  \item The third etc
\end{enumerate}   

\end{document}

enter image description here

As per the comments of Enrico (egreg), if none of the sections need to be numbered, one may use \setcounter{secnumdepth}{-2} in the preamble. This will allow one to use the regular section (without having numbers). This will also enable the use of section titles as the headers.

  • 1
    If no section should have a number, it's easier to write \setcounter{secnumdepth}{-2} in the preamble and use \section; this would take care of headers, should \pagestyle{headers} be called. – egreg Oct 16 '12 at 16:12
  • @egreg Nice point. I have included it in the answer. Thank you :) –  Oct 16 '12 at 16:21
4

You should use \section*{Ingedients} (with the star), and you should add \date{} into your preamble, like this:

\documentclass[10pt]{article}

\date{}

\begin{document}

\title{Banana Cake}
\maketitle


\section*{Ingredients}

\begin{itemize}
  \item The first item
  \item The second item
  \item The third etc
\end{itemize}

\section*{Method}
\begin{enumerate}
  \item The first item
  \item The second item
  \item The third etc
\end{enumerate}



\end{document}

I would recommend you to read some good LaTeX tutorial since these are quite basic things, you can find some hints here: What are good learning resources for a LaTeX beginner?

yo'
  • 51,322