Debian Codegraph @

texmf-dist/doc/latex/bangorexam/README.txt

raw
1 Bangor University Computer Science Department
2 Exam Document Class
3 Cameron Gray <[email protected]>
4 October 4, 2025
5
6 Abstract
7 Starting with the 2016/17 academic year, the Computer Science department at
8 Bangor University have moved to LATEX for preparation of examination papers for all
9 taught courses. This was done for multiple reasons, including the reduction of burden
10 on support staff.
11 This package is the embodiment of that effort. It includes all of the elements needed
12 to produce an examination paper, including examiner’s copies with solutions included.
13
14 1 Usage - Class Options
15
16 The document class is activated (or loaded) using the usual LATEX command
17 \documentclass{bangorexam}. The class requires one of the following options to
18 control which ‘style’ of exam paper is produced.
19 [ab] - produces a compulsory Section A and an ‘n-from’ Section B exam. This type defaults to 2 required to match previous behaviour.
20 [aonly] - produces a single section, all questions compulsory exam.
21 [nfrom] - produces a single part ‘n-from’ exam.
22
23 The ‘answers’ option controls the inclusion of solutions as part of the output.
24 \documentclass[ab]{bangorexam} - produces the student form of a Section A/B
25 exam paper.
26
27 \documentclass[ab]{bangorexam} - produces the student form of a Section A/B exam paper.
28 \documentclass[aonly]{bangorexam} - produces the student form of an exam paper where all questions are compulsory.
29 \documentclass[nfrom]{bangorexam} - produces the student form of an exam paper with a single section but n-from the total questions. \documentclass[ab,answers]{bangorexam} - produces the examiner form of the paper.
30
31 2 Usage - Preamble Macros
32
33 The class includes several macros that must be added to the document’s preamble. These
34 set important aspects such as the module code and title.
35
36 \school{English name}{Welsh name} The name of the school setting this exam, provided in both English and Welsh.
37
38 \module{code}{full name} The code (including the 3-letter prefix) and full name of the module.
39
40 \examperiod{resit|s1|s2} Specifies the period of the exam, s1 for January/End of Semester 1, s2 for May/End of Semester 2, or resit for Supplementary exams (Summer Resits).
41
42 \timeallowed{hours} The amount of time allowed in hours. This should be the numerical part only, e.g. \timeallowed{1\half} or \timeallowed{3}.
43
44 \nfrom{number} The number of compulsory questions from the selection available in the options part of the exam.
45
46 \calculatorallowed Marks the exam as allowing calculators.
47
48 \notesallowed{⟨pages⟩} Marks the exam as allowing notes. When using this option the number of A4 pages/sides must be specified.
49
50 3 Usage - Body Macros
51
52 Various macros exist to typeset the questions within the exam paper. The macros listed
53 here are provided to comply with Bangor University’s style and formatting requirements.
54 Users should not adjust any formatting, font, header, footer, margin other other display
55 parameters. Please use \emph{} for italic text and \textbf{} for boldface fonts only.
56 The document class has been designed to support amsmath and amssymb mathematics
57 typesetting with the conventional font.
58
59 \sectiona Only applies when class option ab is active. Begins the compulsory Section A.
60
61 \sectionb Only applies when class option ab is active. Begins the student-choice Section B.
62
63 \pointsdesc{description}Sets the suffix/descriptive text following a points value. This defaults to an empty string, so 5 points would be rendered as [5]. Setting \pointsdesc{%} would result in [5%].
64
65 \guidance{guidance text} Sets a ’guidance’ paragraph on the cover page.
66
67 \guidancea{guidance text} Sets a ’guidance’ paragraph at the start of section A only.
68
69 \guidanceb{guidance text} Sets a ’guidance’ paragraph at the start of section B only.
70
71 4 Usage - Environments
72
73 There are three key environments questions, parts, and solution. These represent a
74 numbered sequence of questions, parts and sub-parts of one question, and a solution/answer
75 for a question respectively.
76
77 4.1 Questions Environment
78
79 All questions must be set within a questions environment. You may add other items, such
80 as explanations, images, scenarios etc., in this environment too. The most simple questions environment is as follows:
81 \begin{questions}
82 \end{questions}
83
84 However, this will not actually produce any output.
85 Questions must be added with use of the \question macro.
86
87 \question[points] Question Text
88
89 This macro can only be used within the Questions environment and is used to typeset a
90 question. The optional argument sets the number of points/marks/percentage awarded for
91 correct answers. See the \pointsdesc macro for customisation options.
92 Whenever a new block is started (with \begin{questions}), the numbering begins at
93 1. (Questions, at present, can only be labelled with Arabic numerals.)
94
95 4.2 Parts Environment
96
97 Within a question, examiners may wish to have multiple sub-questions (a.k.a parts). This is provided for by the \begin{parts}...\end{parts} environment. Each sub-question
98 or part is handled with the part macro.
99
100 \part[points] Part Text
101
102 This macro can only be used within the parts environment and is used to typeset a subquestion. The optional parameter sets the number of points/marks/percentage awarded for
103 correct answers. See the \pointsdesc macro for customisation options.
104
105 The parts environment may only be used within the questions environment, as in the
106 example below:
107 \begin{questions}
108 \question Use the graph in Figure 1 to answer the following:
109 \begin{parts}
110 \part Sub-question 1
111 \part[10] Sub-question 2
112 \end{parts}
113 \end{questions}
114
115 Whenever a new block is started (with \begin{parts}), the sub-question numbering
116 begins with a). (Sub-questions, at present, can only be labelled with English letters).
117
118 4.3 Solution Environment
119
120 Following either a \question or \part, the examiner should include a solution block.
121 This block/environment will only be included if the answers class option is in effect. (See Class Options for more details). Any standard LaTeX content can be placed in a solution block. A minimal example is below:
122 \begin{questions}
123 \question A really hard question.
124 \begin{solution}
125 The answer is placed here.
126 \end{solution}
127 \end{questions}
128
129 5 Usage - Multiple Choice Questions
130
131 There are four environments that will allow typesetting of multiple choice selections
132 depending on the desired layout. All must be used within a Questions or Parts environment.
133 The first pair present a list of possible responses labelled with letters. The choices
134 environment presents one choice per line, whereas the horizontalchoices environment
135 lays out choices in a single paragraph, wrapping lines wherever necessary.
136 The second pair present tick or check boxes instead of labelled choices. A checkboxes
137 environment will again typeset options one to a line, and the horizontalcheckboxes
138 environment will present all options in one paragraph.
139 Within any of the four environments each choice is typeset using the choice macro. Please
140 note; there is no points argument for individual choices, this should be handled at the
141 question or part level.
142
143 \choice Choice Text
144
145 Typesets a single choice according to which environment it is placed in.
146 Solutions to multiple choice questions are handled somewhat differently. Instead of a
147 solutions environment, typeset the correct option using the correctchoice macro.
148
149 \correctchoiceChoice Text
150
151 Typeset the correct choice based on where the macro is placed. When answers is in effect,
152 the output of this macro will either highlight the option in boldface, or replace the checkbox with a tick.