Starting an enumerate of an enumerate on next line?

What I'm trying to do is to make my enumerates look like this

a)


Currently, I'm using

\begin{enumerate}
\item \hfill \\
\begin{enumerate}[a)]
\item
\item
\end{enumerate}
\end{enumerate}


but it looks like there are 2 empty lines when I do this, instead of one.

a)

i)


I have tried a lot of spacing commands, but I couldn't get them to work (new to LaTeX).

So, Is there a way to do this? or should i just put them all on the same line? I know its easier but I think it looks weird.

-
"Or should I just put them all on the same line?" Yes, that's what I'd recommend, at least if this doesn't destroy alignment of "i)" with "ii)". That case could also be dealt with. –  Hendrik Vogt Jan 24 '11 at 11:47

Anything that creates an empty box or adds some white space will do the trick. For example \mbox{} or even \hfill. The problem with \hfill\\ is that it fills the line, then creates a new line and then creates a new paragraph for the list; so there is to much vertical white space.

\begin{enumerate}
\item \mbox{}
\begin{enumerate}
\item
\item
\end{enumerate}
\end{enumerate}


-
I misunderstood '\hfill', I thought it would fill in the horizontal space only if there was another character after it, sort of like a justification. At least now its fixed. \hurray! –  Buttink Jan 24 '11 at 4:28

If you wish all your {enumerate} to behave like this, you can patch the \item command to add a \leavevmode (which has the same effect here as the \mbox{} suggested by Caramdir) to automate all this. The patching can be done through the \apptocmd command from the etoolbox package which appends code at the end of a command. You cannot directly append to enumerate and item if you want to be able to use optional arguments (you need to patch \\enumerate and \@item for this). In the following code, I've also used the enumitem package to customize the lists (it allows to automatically have a), b), etc. for second level {enumerate}).

\documentclass{article}
\usepackage{enumitem}
\setenumerate[2]{label=\alph*)}
\usepackage{etoolbox}
\makeatletter
\expandafter\apptocmd\expandafter{\csname\string\enumerate\endcsname}{\apptocmd{\@item}{\leavevmode}{}{}}{}{}
\makeatother
\begin{document}
\begin{enumerate}
\item \begin{enumerate}
\end{enumerate}

The code \apptocmd{\@item}{\leavevmode}{}{} appends to \item a \leavevmode which always starts a new line after an \item inside an {enumerate}. To restrict this to {enumerate} environments only, this code is itself append to \enumerate thanks to another \apptocmd.
A final note on this code: if you nest an {itemize} inside a {enumerate}, the \item will also have been redefined (if that's a problem, it's not difficult to patch {itemize} to keep the original definition of \item).