如何将文本与项目符号对齐

如何将文本与项目符号对齐

问题是当项目符号超过一行时。然后对齐就会像这样被破坏。

在此处输入图片描述

我发现可以通过添加空格来分隔行来解决此问题,但这感觉不是最佳选择。有没有更优雅的解决方案?

\documentclass{article}

\begin{document}
\begin{enumerate*}
\item(a) Let $n$ and $m$ be integers such that $n < m$ and $m \neq 0$. Then $(\frac{n}{m})^2 \leq (\frac{n}{m})$.

\item(b) Every abelian group is cyclic.

\item(c) The group of permutations $S_3$ of \{1,2,3\} is abelian.

\item (d) If * is any commutative binary operation on any set S, then $a * (b * c) = (b * c) * a$.

\item (e) If * is any binary operation on any set S then $a * a = a$ for all $a \in S$. 

\item (f) Every finite group of at most four elements is cyclic.

\item (g) The empty set is a group.

\item (h) The group of permutations $S_{10}$ of \{1,2,3, \dots ,10\} has 10 elements. 

\item (i) The product of any two cycles in the group of permutations $S_8$ of \{1,2,3, \dots,8\} is commutative

\item (j) The set of all $3 \times 3$ matrices with determinant $-1$ is a subgroup of the group GL $(3, \mathbb{R})$, where GL $(3, \mathbb{R})$ is the group of all invertible $3\times 3$ matrices with real number entries. 
\end{enumerate*}
\end{document}

答案1

enumerate需要有列表缩进。因此,您应该使用enumerate(或类似)两个都在您的问题和解决方案中。在这种情况下,我手动使用\emph{Solution},但您应该查看一些考试包。

请注意,它是If $*$ is any blah blah而不是If * is any blah blah。他们是不同的! 另外,有些地方也需要数学模式。

\documentclass{article}
\usepackage[shortlabels]{enumitem}
\usepackage{amssymb}
\makeatletter % https://tex.stackexchange.com/a/1960/156344
\def\old@comma{,}
\catcode`\,=13
\def,{%
  \ifmmode%
    \old@comma\discretionary{}{}{}%
  \else%
    \old@comma%
  \fi%
}
\makeatother
\begin{document}
\noindent\emph{Solution}
\begin{enumerate}[(1)]
\item Let $n$ and $m$ be integers such that $n < m$ and $m \neq 0$. 
Then $(\frac{n}{m})^2 \leq (\frac{n}{m})$.
\item Every abelian group is cyclic.
\item The group of permutations $S_3$ of $\{1,2,3\}$ is abelian.
\item If $*$ is any commutative binary operation on any set S, then 
$a * (b * c) = (b * c) * a$.
\item If $*$ is any binary operation on any set $S$ then $a * a = a$ 
for all $a \in S$. 
\item Every finite group of at most four elements is cyclic.
\item The empty set is a group.
\item The group of permutations $S_{10}$ of $\{1,2,3,\ldots,10\}$ has
10 elements. 
\item The product of any two cycles in the group of permutations 
$S_8$ of $\{1,2,3,\ldots,8\}$ is commutative.
\item The set of all $3 \times 3$ matrices with determinant $-1$ is a
subgroup of the group $\mathrm{GL}(3, \mathbb{R})$, where 
$\mathrm{GL}(3,\mathbb{R})$ is the group of all invertible $3\times 
3$ matrices with real number entries. 
\end{enumerate}
\end{document}

在此处输入图片描述

相关内容