LaTeX 编号列表的写法
enumerate 环境给每个 \item 编号 1、2、3;嵌套列表依次改用 (a)、i.、A.,enumitem 宏包则可以修改编号样式。
LaTeX 命令
\begin{enumerate} \item First \item Second \end{enumerate}不是你要找的符号?画出来查命令 →
正在把手写笔记敲成 LaTeX?整页手写一次转成 LaTeX →
先写 \begin{enumerate},每一步写一个 \item,最后写 \end{enumerate}。LaTeX 会自动计数,所以移动一项后,其余各项会重新编号。最多可以嵌套四层;标准编号依次是 1.、(a)、i. 和 A.。
使用 enumitem 时,在列表选项中设置 label:label=(\alph*) 得到 (a)、(b)、(c);label=\Alph*. 得到 A.、B.;label=\roman*) 得到 i)、ii)。start=2 表示从 2 开始,resume 则在中间隔了一段文字之后,接着上一个列表继续编号。
不用 enumitem 时,紧跟在 \begin{enumerate} 后面写 \setcounter{enumi}{1},第一项就会编号为 2。单独一项可以用 \item[(c)] 显示任意编号。给某一项加上 \label,就能在其他地方用 \ref 引用它的编号。
字母、罗马数字与其他起始编号(enumitem)
加载 enumitem,然后在方括号里给每个列表设置 label、start 或 resume。
\usepackage{enumitem}\begin{enumerate}[label=(\alph*)]\begin{enumerate}[start=2]\begin{enumerate}[resume]其他写法
\begin{enumerate}[label=(\alph*)](a)、(b)、(c),enumitem\begin{enumerate}[start=2]从 2 开始,enumitem\begin{enumerate}[resume]接续编号,enumitem\begin{enumerate}[label=\roman*.]i.、ii.、iii.,enumitem示例
$\begin{array}{l} 1.\;\text{First item} \\ 2.\;\text{Second item} \end{array}$enumerate 的输出效果
$\begin{array}{l} (a)\;\text{Differentiate.} \\ (b)\;\text{Integrate.} \end{array}$用字母编号的小题,label=(\alph*)
$\begin{array}{l} 1.\;\text{Algebra} \\ \quad (a)\;\text{Linear} \\ \quad (b)\;\text{Quadratic} \end{array}$嵌套列表
使用技巧与常见错误
- 让 LaTeX 自动计数:不要自己输入编号。
- 字母和罗马数字编号用 enumitem 的 label 选项。
- 用 start=... 从其他数字开始,或者用 resume 接续编号。
- 用
\label标记某一项,再用\ref引用它,这样编号始终正确。 - 嵌套列表会自动更换编号样式:1.、(a)、i.、A.。
手上是手写笔记?
LatexNotes 能把手写数学的照片或 PDF 转换成 LaTeX,连手绘图形也一并转换。交到你手上之前已用真正的 pdflatex 编译好,.tex 文件归你所有,可以继续编辑或带到 Overleaf。免费试用,无需注册。
分步了解手写转 LaTeX的做法;如果你在 iPad 上记笔记,请看 GoodNotes 转 LaTeX(Notability 用法相同)。
把你的数学笔记转成 LaTeX →常见问题
LaTeX 中编号列表怎么写?
用 \begin{enumerate} \item First \item Second \end{enumerate}。
怎么用字母 a、b、c 编号?
加载 enumitem,写 \begin{enumerate}[label=(\alph*)];或者写 label=\alph*. 得到 a.、b.。
编号列表怎么从 2 开始?
使用 enumitem 时写 \begin{enumerate}[start=2]。不用它时,紧跟在 \begin{enumerate} 后面写 \setcounter{enumi}{1}。
怎么接着上一个列表继续编号?
加载 enumitem,然后写 \begin{enumerate}[resume]。