Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

I have use enumerator before, that is good when it comes to numbering with letters after your initial number such as 2a, 2b etc. But now I have problem where I want to number my questions 2.1.1, 2.1.2. I tried to use the enumerator

\textbf{Question 2.1}\\
\HRule
\begin{enumerate}[(2.1.1)]\itemsep1pt

\end{enumerate}

But this gives me error, what would it the best way to handle this situation.

share|improve this question
6  
Could you provide a complete MWE? Is 'Question' some kind of environment? In general, you should never hard code enumerations in LaTeX, and let it handle them using counters –  cmhughes Feb 15 '13 at 16:48
add comment

1 Answer 1

up vote 2 down vote accepted

You can do this with the list environment fairly easily

Below is lifted from http://www.maa.org/latex/ltx-260.html

\documentclass{amsart}
\begin{document} 

\newcounter{Lcount}

\begin{list}{2.1.\arabic{Lcount}}{\usecounter{Lcount}\setlength{\rightmargin}{\leftmargin}}
\item $f(x)=x^2$ Find $f'(x)$
\item What is an antiderivative of $f(x)=x^2$
\end{list}
\end{document}

I do however agree it is bad form to hard code numbering of questions. But if you're just making your own exams I could see why you might do this.

share|improve this answer
    
This answer cannot be correct. Either it is not what OP asks for, or this is a solution that is systematically mis-conceptual and should never be advised. –  tohecz Feb 15 '13 at 17:20
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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