File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -163,28 +163,29 @@ assert grade(85) == 'B'
163163assert grade(69) == 'F'
164164 </input ></program >
165165
166-
167- <!-- .. reveal:: ac_grade_unittest_aux_reveal-->
168- <!-- :instructoronly:-->
169- <!-- .. actex:: ac_grade_unittest_aux-->
170- <!-- testA = False-->
171- <!-- testB = False-->
172- <!-- testF = False-->
173- <!-- illegal = False-->
174- <!-- def grade(score):-->
175- <!-- global illegal, testA, testB, testF-->
176- <!-- if score > 100 or score < 0:-->
177- <!-- illegal = True-->
178- <!-- return ''-->
179- <!-- elif score >= 90:-->
180- <!-- testA = True-->
181- <!-- return 'A'-->
182- <!-- elif score >= 80:-->
183- <!-- testB = True-->
184- <!-- return 'B'-->
185- <!-- else:-->
186- <!-- testF = True-->
187- <!-- return 'F'-->
166+ <commentary >
167+ ac_grade_unittest_aux_reveal
168+ instructoronly
169+ actex:: ac_grade_unittest_aux
170+ testA = False
171+ testB = False
172+ testF = False
173+ illegal = False
174+ def grade(score):
175+ global illegal, testA, testB, testF
176+ if score > 100 or score < 0:
177+ illegal = True
178+ return ''
179+ elif score >= 90:
180+ testA = True
181+ return 'A'
182+ elif score >= 80:
183+ testB = True
184+ return 'B'
185+ else:
186+ testF = True
187+ return 'F'
188+ </commentary >
188189 </solution >
189190 </exercise >
190191 </subsection >
You can’t perform that action at this time.
0 commit comments