2

I simply want to nest lists for answering homework problems with multiple parts as such

\begin{description}
 \item[3]
 \item[5]
\begin{enumerate}
  \item
  \item
 \end{enumerate}
\end{description}

and to have the nested list all aligned. I can't find a way to do this automatically, and I know the answer may be simple but this is bothering me a lot. My document class is article and I tried using enumitem with no success.

4

The description environment naturally has a 'hanging' indent after the first line, which is giving your 'undesired' output.

It sounds like it would be more appropriate to use an itemize environment in your particular case, which gives the following output:

screenshot

Here's the code:

% arara: pdflatex
\documentclass{article}
\begin{document}
\begin{itemize}
 \item[3]
 \item[5]
\begin{enumerate}
  \item
  \item
 \end{enumerate}
\end{itemize}
\end{document}

If you want the first-level items to be bold then you can use the enumitem package to help

screenshot bold

% arara: pdflatex
% !arara: indent: {overwrite: yes}
\documentclass{article}
\usepackage{enumitem}

\setlist[itemize]{font=\bfseries}

\begin{document}
\begin{itemize}
    \item[3]
    \item[5]
          \begin{enumerate}
            \item
            \item
          \end{enumerate}
\end{itemize}
\end{document}
0
1

Some variation on @cmhughes's solution: load enumitem with the shortlabels option and use enumerate in both cases:

        \begin{enumerate}[\bfseries1. ]
         \item
         \item
        \begin{enumerate}[1)]
          \item
          \item
         \end{enumerate}
        \end{enumerate}

givesenter image description here

Or, if you want the labels of both lists at the left margin, use the same preamble and this code:

        Lalala…
                    \begin{enumerate}[\bfseries1.,wide,labelindent = 0pt]
                     \item
                     \item
                    \begin{enumerate}[1),,wide, labelindent = 0pt]
                      \item
                      \item
                     \end{enumerate}
                    \end{enumerate}
        Lalala…

enter image description here

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.