1

For enumerate there are options like start or resume or commands like \setcounter{enumi}{4} or \addtocounter{enumi}{41} as discussed in questions like How can I make an enumerate list start at something other than 1? or Resuming a list.

Are there analogous possibilities for the parts environment in the exam document class?

\documentclass{exam}

\begin{document} \begin{questions} \question[10] Some not indented text \begin{parts} \part this should be (a) \part this should be (b) \end{parts} Some more not indented text interrupting the parts \begin{parts} \part this should be (c) \part this should be (d) \end{parts} \end{questions} \end{document}

Jakob
  • 993

1 Answers1

3

\setcounter{partno}{3} or \addtocounter{partno}{5} are possibilities (inspired by https://tex.stackexchange.com/a/81720/128042), but a bit less elegant than the automatic resume option for enumerate.

https://tex.stackexchange.com/a/1702/128042 would be slightly less hard codes but a bit more code:

\documentclass{exam} 
\newcounter{nameOfYourChoice}
\begin{document}
\begin{questions}
\question[10]
Some not indented text
\begin{parts}
    \part this should be (a)
    \part this should be (b)
    \setcounter{nameOfYourChoice}{\value{partno}}
\end{parts}
Some more not indented text interrupting the parts
\begin{parts}\setcounter{partno}{\value{nameOfYourChoice}}
    \part this should be (c)
    \part this should be (d)
\end{parts}
\end{questions}
\end{document}
Jakob
  • 993