4

I need to do some nested numbering of items, but with skips. I can skip outer numbering, but similar method is not working with inner numbering. I have the code below, where the numbering starts from 2, as desired, but the inner numbering does not start from (e). How would I go about achieving this.

\begin{enumerate}
    \setcounter{enumi}{1}
    \item
    \begin{enumerate}
        \setcounter{enumi}{4}       
        \item My answer to 2e.
    \end{enumerate}
\end{enumerate}

Note: The need for doing this arises for a redo of some homework questions.

  • 2
    You want to adjust \enumii, \enumiii etc as you go deeper. – Masroor Sep 10 '13 at 7:59
  • 2
    The second counter is enumii with two i at the end. – Ulrike Fischer Sep 10 '13 at 8:00
  • Works great, I could have never imagined that myself :). Please add that as an answer. – Shamim Hafiz Sep 10 '13 at 8:04
5

It's much easier with »enumitem«.

\documentclass[11pt]{article}
\usepackage[T1]{fontenc}
\usepackage{enumitem}

\begin{document}
  \begin{enumerate}[start=2]
    \item
    \begin{enumerate}[start=5]
      \item My answer to 2e.
    \end{enumerate}
  \end{enumerate}
\end{document}
5

The problem is the counter you are using. enumi is for the first level, for the second level you have to use enumii, third would be enumiii. So your code should be as below:

\begin{enumerate}
    \setcounter{enumi}{1}
    \item
    \begin{enumerate}
        \setcounter{enumii}{4}       
        \item My answer to 2e.
    \end{enumerate}
\end{enumerate}

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.