Sharedsupport / 2016-04-18-exam / example.texOpen in CoCalc
Authors: Harald Schilly, William A. Stein
Description: Examples for support purposes.
1\documentclass{exam}
2\usepackage[utf8]{inputenc}
3\usepackage{sagetex}
4
5\begin{document}
6
7\begin{center}
8\fbox{\fbox{\parbox{5.5in}{\centering
9Answer the questions in the spaces provided. If you run out of room
10for an answer, continue on the back of the page.}}}
11\end{center}
12
13\vspace{5mm}
14
15\makebox[\textwidth]{Name and section:\enspace\hrulefill}
16
17\vspace{5mm}
18
19\makebox[\textwidth]{Instructor’s name:\enspace\hrulefill}
20
21\begin{questions}
22\question Compute the prime factorization of $\sage{ZZ.random_element(10,600)}$.
23
24\question Find the derivative of
25$$26 f(x) = \sage{QQ['x'].random_element(3)}. 27$$
28
29\question What is the determinant of $$A = \sage{random_matrix(ZZ, 3)}?$$
30
31\end{questions}
32
33\end{document}