# exam-zh: LaTeX template for Chinese exam

Provides a class exam-zh.cls and its several module packages like exam-zh-question.sty and exam-zh-choices.sty, where these module packages can be used individually. 

Although there are several excellent exam packages or classes uploaded before like exam and bhcexam , they don't fit the chinese style very well or they cannot be customized easily for chinese exam of all types like exams in primary school, junior high school, senior high school and even college. Those are the main reason why exam-zh was created.

In exam-zh, you can

- seperate the format and the content very well;
- use choices environment to typeset choice items easily and automatically;
- design the sealline easily;
- use it in Windows, macOS and Linux;
- ... (for more that you can do with it, please read the manual���in Chinese���: `exam-zh-doc.pdf`
- QQ group: 652500180


Repository: https://gitee.com/xkwxdyy/exam-zh
Author: Zeping Lee
Maintainer: Kangwei Xia, Lijun Guo
Issues and pull requests are welcome: [issues]( https://gitee.com/xkwxdyy/exam-zh/issues) and [pulls](https://gitee.com/xkwxdyy/exam-zh/pulls)

# exam-zh��������������� LaTeX ������

- ���������������<https://gitee.com/xkwxdyy/exam-zh>
- ���������Zeping Lee
- ������������Kangwei Xia, Lijun Guo
- ���������[LaTeX Project Public License 1.3c](https://www.latex-project.org/lppl.txt)
- QQ ������������������652500180


��������������������������������������������������� LaTeX ������������������������������������������������������ LaTeX������������������������������

1. ���������������������������������
2. ������������������������������������������������������
3. ������������������������������������������������������
4. ��� Windows, macOS ��� Linux ������������������

������������������������ [���������](https://gitee.com/xkwxdyy/exam-zh/releases) ��������������� `exam-zh-doc.pdf`���

## ���������simple example���

```latex
\section{��������������������� 8 ������������������ 5 ��������� 40 ������}

\begin{question}
  ��������� $A = \{x \mid -1 < x < 4\}$���$B = \{2, 3, 4, 5\}$������ $A \cap B = $ \paren
  \begin{choices}
    \item $\{2\}$
    \item $\{2, 3\}$
    \item $\{3, 4\}$
    \item $\{2, 3, 4\}$
  \end{choices}
\end{question}

\section{��������������������� 4 ������������������ 5 ��������� 20 ������}

\begin{question}
  ������������ $f(x) = x^3 (a \cdot 2^x - 2^{-x})$ ������������������ $a = $ \fillin ���
\end{question}

\section{��������������������� 6 ������������ 70 ���������������������������������������������������������������������}

\begin{problem}[points = 12]
  ������������ $f(x) = x (1 - \ln x)$��������� $f(x)$ ���������������
  ��� $a$���$b$ ��������������������������������� $b \ln a - a \ln b = a - b$���
  ���������$2 < \frac{1}{a} + \frac{1}{b} < \eu$���
\end{problem}
```


## ������������

������������������ `exam-zh` ������������������**��������������������������������� `exam-zh-doc.pdf`���**
### ���������������������

������������������������������������������������

```tex
\examsetup{
  font      = times,
  math-font = xits,
}
```

������������ `font` ������������������
- `newcm`������������New Computer Modern
- `lm` Latin Modern
- `times` Times New Roman
- `termes` TeX Gyre Termes
- `stix` STIX Two
- `xits` XITS
- `libertinus` Libertinus

������������ `math-font` ������������������
- `newcm`������������New Computer Modern Math
- `lm` Latin Modern Math
- `termes` TeX Gyre Termes Math
- `stix` STIX Two Math
- `xits` XITS Math
- `libertinus` Libertinus Math
- `cambria` Cambria Math

��������������������������� `unicode-math` ���������������������


### ������������ `question` ��� `problem`

��������������������������� `question` ������������������������ `problem` ���������������������������������������������

`question` ��� `problem` ������������������������������������������������������������ key���value ���������������
- `answer-color` ���������������������������`black`������
- `index` ���������
- `points` ���������������������������`0`������
- `show-paren` ��������������������������������������� `false`������
- `show-points` ������������������������������������ `auto`������������������������������ `false`������������������ `true`������
- `show-answer` ������������������������������`false`������
- `top-sep` ���������������������������������������������������`.5em plus .5em minus .2em`������
- `bottom-sep` ��������������������������������������������� `top-sep` ���������������������`.5em plus .5em minus .2em`������

������ `index`���`show-points`���`show-answer`���`top-sep` ��� `bottom-sep` ������������ `\examsetup` ��������� `choices` ���������������������������������������������������������������������
```latex
\examsetup{
  choices = {
    show-points = true,
    show-answer = true,
  },
}
```
���������������������/���������������������������������
```latex
\examsetup{
  question/show-points = true,
  question/show-answer = true,
}
```


### ������������������ `\paren` ��������� `\fillin`

`\paren` ��� `\fillin` ��������������������������������������������������������������������������������������������������������������������������������������� `\paren[B]` ��� `\fillin[foo]`������ `show-answer = true` ���������������������������������

��������������������������� `\fillin` ��������������������������������������������������������� `\fillin[$(���\infty, 1]$]`������������������������������������������������������`\fillin[{$(���\infty, 1]$}]`���

`\fillin` ���������������������������������������������������������������������
```latex
\examsetup{
  fillin = {
    type = paren    % ������������ 
    % type = line    % ���������������
  }
}
```
��������������������������� `\fillin` ������������`\fill[type = paren][foo]`������������������`\fill[type = paren][]`���������������


### ������������ `choices`

������������������������ `choices` ������������������������������������������������������������������������������������������������������������������ @xkwxdyy ��� [choices-l3](https://gitee.com/xkwxdyy/choices-l3) ��� [xchoices](https://gitee.com/xkwxdyy/xchoices) ���������
```latex
\begin{choices}[label-pos = top-left]
  \item $\{2\}$
  \item $\{2, 3\}$
  \item $\{3, 4\}$
  \item $\{2, 3, 4\}$
\end{choices}
```
��������������������������� key���value ������������������������������ `label-pos` ���������������������������
- `index`       ��������������������������������������������������������� `1`������
- `column-sep`  ��������������������������������������� `1em`������
- `columns`     ��������������������������������������������� 0 ��������������������������������������� `0`������
- `label-align`������������`left`, `center`, `right`��������� `right`���������������������������������
- `label`       ������������������������ `enumitem` ��������� `\Roman` ��������������� `*` ��������������������� `\Alph*.`������
- `label-pos`   ���������������������������������������`auto` ������������������������������������������������������������������������������������������������ `left`������������������������������������������������`top-left`���������������`auto`, `top-left`, `left`, `bottom`��������� `auto`������
- `label-align` ������������������������������������������`left`, `center`, `right`��������� `right`���
- `label-sep`   ��������������������������������������� `0.5em`������
- `label-width` ������������������������������������������������������������������������������������ `0pt`������
- `max-columns` ������������������������������������������������������������������������������������������������������������������ 2 ������������������������������������������������������������������ `4`������

������������������������ `\examsetup` ��������� `choices` ��������������������������������� `question`���

`exam-zh-choices` ������������������ `\circlednumber` ��������������������������������������������������������������������� LaTeX2e ������������������������ `section`��������������������������������������������������������� `\circlednumber{7}`������������ 0���50 ������������������������������������������������ 10 ������������������������������ 10 ���������������������

��������������������������������������������������� `choices` ������������������������ `\AddChoicesCounter` ��������������������� `label` ��������������������������������� `enumitem` ��� `\AddEnumerateCounter`��������������������� `\AddChoicesCounter{���LaTeX command���}{���internal command���}{���widest label���}`��������� `���LaTeX command���` ������ `label` ���������������������`���internal command���` ���������������������`���widest label���` ���������������������������������������������������������`\AddChoicesCounter{\circlednumber}{\__examzh_choices_circled_number:n}{1}`���


### ������������ `solution` ��������������� `\score`

```latex
\begin{solution}
  ��������������������� $(0, +\infty)$,
  ��� \[f^{\prime}(x) = 1 - \ln x-1 = -\ln x, \score{2}\]
  ��� $x \in(0, 1)$ ���, $f^{\prime}(x) > 0$, ��� $x \in(1, +\infty)$ ���, $f^{\prime}(x) < 0$,
  ��� $f(x)$ ������������������ $(0,1)$, ��������������� $(1, +\infty)$.
\end{solution}
```
��������������������������������������� `\score` ���������������������������������������������������������������������

### ���������������������

��������������������������������������������������������������������� `\eu` ��� `\iu` ���������������������������������e���������������������i������`\eu` ��������������� ���e upright��� ��������������� ���Euler's number��� ���������������`\iu` ��������������� ���i upright��� ��� ���imaginary unit��� ����������������������������������������������������������������� `\uppi` ���������


### ���������

```latex
  \examsetup{
    sealline = {
      show        = true,
      % scope        = firstpage,
      % scope        = oddpage,
      scope        = everypage,
      line-thickness       = 1pt,
      line-xshift          = 8mm,
      line-yshift          = 0mm,
      line-type            = densely-dashed,
      text                 = ������������������������,
      text-xshift          = 11mm,
      text-yshift          = 30mm,
      circle-show          = true,
      circle-start         = 0.07,
      circle-end           = 0.92,
      circle-step          = 3.5em,
      circle-diameter      = 3mm,
      circle-xshift        = 8mm,
      odd-info-content     = {
        {\kaishu ������}���{\underline{\hspace*{8em}}},
        {\kaishu ������������}���{\underline{\hspace*{8em}}},
        {\kaishu ���������}���{\underline{\hspace*{8em}}},
        {\kaishu ���������}���{\underline{\hspace*{8em}}},
      },
      odd-info-seperator   = \hspace*{3em},
      odd-info-align       = center,
      odd-info-xshift      = 20mm,
      odd-info-yshift      = 0mm
    }
  }
```

��������������������������������������������������������������������������������������� `exam-zh-doc.pdf`���

## ������

��������������������������������������������������������������� issue ���������������������������������������������������



## ������������

������������ LaTeX Project Public License v1.3 ���������������




## ������������

- Philip Hirschhorn, `exam`: <https://www.ctan.org/pkg/exam>
- ��������� `BHCexam`: <https://github.com/mathedu4all/bhcexam>
- ��������� `jnuexam`: <https://www.ctan.org/pkg/jnuexam>
- @htharoldht `USTBExam`: <https://github.com/htharoldht/USTBExam>
- ��������� `GEEexam`: <https://github.com/shaodongtang/gaokao_exam>
- ��������� `CMC`: <https://github.com/shaodongtang/CMC>
- @sd44 `DANexam`: <https://github.com/sd44/DANexam>
- ��������� `simplexam`: <https://github.com/hushidong/simplexam>