diff options
author | Karl Berry <karl@freefriends.org> | 2008-09-08 00:42:04 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2008-09-08 00:42:04 +0000 |
commit | 036469499e69e21110bdbbd77af3e90de86a382a (patch) | |
tree | 34d517f0b3490d8eed24f45e7bd1ce7ab63ab825 /Master/texmf-dist/doc/latex/probsoln/samples/sample2.tex | |
parent | 2f2e79372e149e87d92bdd0d33d596793e6b1252 (diff) |
probsoln 3.0 (27aug08)
git-svn-id: svn://tug.org/texlive/trunk@10474 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/doc/latex/probsoln/samples/sample2.tex')
-rw-r--r-- | Master/texmf-dist/doc/latex/probsoln/samples/sample2.tex | 47 |
1 files changed, 47 insertions, 0 deletions
diff --git a/Master/texmf-dist/doc/latex/probsoln/samples/sample2.tex b/Master/texmf-dist/doc/latex/probsoln/samples/sample2.tex new file mode 100644 index 00000000000..e82656c9f3a --- /dev/null +++ b/Master/texmf-dist/doc/latex/probsoln/samples/sample2.tex @@ -0,0 +1,47 @@ +\documentclass[a4paper]{article} + +\usepackage{probsoln} + %uncomment the following line to display the answers +\showanswers + + % The following will generate a different set of + % problems in subsequent years + %\PSNrandseed{\year} + + % The following will generate a different set of + % problems on every run (where each run is at + % least a minute apart from the previous one) +\PSNrandseed{\time} + +\begin{document} +\title{Sample Problem Sheet} +\author{Nicola Talbot} +\maketitle + +\begin{enumerate} + +\newcounter{numproblems} + % store a random number from 1 to 3 in the counter numproblems +\random{numproblems}{1}{3} + + % selects 1,2 or 3 problems from 1 of the given files: +\doforrandN{1}{\file}{1stprncp,implicit}{\selectrandomly{\file}{\value{numproblems}}} + +\item Differentiate the following functions: +\input{args}% load database +\begin{enumerate} +\newcounter{A} +\newcounter{B} +\newcounter{C} +\random{A}{-4}{5} +\random{B}{-3}{3} +\random{C}{-1}{10} +\item \useproblem{diff:quad}{\arabic{A}}{\arabic{B}}{\arabic{C}} + +\random{A}{-5}{5} + % make sure its not 0 +\whiledo{\value{A}=0}{\random{A}{-5}{5}} +\item \useproblem{diff:sin}{\arabic{A}} +\end{enumerate} +\end{enumerate} +\end{document} |