Dear Math LaTeX Community,

I'm creating some worksheets/problem sets for a high school pre-alg class and have included the option to print solutions.

Is it possible to print the answers in a box without the title "SOLUTION S".

I searched for an answer in stackexchange and also reviewed section 8 of Hirschhorn's Using the exam document class.

Either I'm not understanding the "exam doc" class or there's an error in my code that forces the title "solution" to print in every answer box. In the hope that one of you generous souls will take pity on me and provide a solution for this issue, I have posted the relevant portion of my code below.

Many thanks to all of you who take time to read this post!

WyoWindStorm LaTeX newbie


%\printanswers % uncomment to print solutions. \printanswers % MACROS %Not sure all of these packages are necessary...but the 'taks package is certainly necessary \usepackage{amsmath} \usepackage{cancel} \usepackage{tikz} \usepackage{graphicx} \usepackage{pgfplots} \usepackage{caption} % allows captions in minipage envir (issue w/solutions envir) \usepackage{amssymb} \usepackage{mathrsfs} \usepackage{framed} %box para \usepackage{tkz-euclide} \usepackage{multicol} \usepackage{tasks} \pgfplotsset{compat=1.10} %\displaystyle for all $$ math environments use \lim\limits for other environments



%\unframedsolutions % uncomment to remove boxes from solutions \setlength{\parindent}{0pt} % removes paragraph indentation

\pagestyle{head} \header{Pre-Alg Pd #5: Exponent Concepts Covered in Class on 04-04-19 (D11)} {} {04/05/19}

\newcommand{\pagetop}{% \makebox[\textwidth]{Name:\enspace\hrulefill}\par \vspace{4mm} \fbox{\fbox{\parbox{\dimexpr\textwidth-4\fboxsep-4\fboxrule}{ \textbf {Simplify by expansion and steps shown in class. Your answer should have only POSITIVE EXPONENTS. \bigskip \Show all work/steps on this page.}

}}}\par \bigskip \vspace{0.5mm} }

\settasks{after-item-skip=15em, after-skip=2cm, label-width=2em, item-indent=3em, %change '1' to 'a' if you want letters instead of numbers counter-format=(tsk[1]), column-sep=2em }

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % -------------------------- DOCUMENT STARTS HERE ------------------------- %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\begin{document} https://www.overleaf.com/project/5ca66096f91606440362a785 \pagetop


% Prob #1 \task $4y\cdot 2y^3\cdot3x^{-2}$ \begin{solution} $4^1$ \end{solution}

% Prob #2 \task $4xy^0\cdot x^{-2}y^{-3}\cdot y^0$ \begin{solution} solution \end{solution}

% Prob #3 \task $\frac{3y\cdot2xy^2}{3x^{-2}y^4}$ \begin{solution} solution \end{solution}

% Prob #4 \task $\frac{xy^{-3}}{3x^3y^{-2}\cdot2x^{-3}y}$ \begin{solution} solution \end{solution}

% Prob #5 \task $\frac{m^{-4}n^4\cdot(mn^2)\strut^{-3}}{(m^2n^4)\strut^0}$ \begin{solution} solution \end{solution}




You can ad the rule


full code:

\question question1
Your answer 

Resulting in:

enter image description here

  • Thanks very much for the quick and accurate response, Arne. Being a LaTeX newbie, the only that initially confused was the need to replace this code.....\begin{solution} $4^1$ \end{solution}..... with \{solutionorbox} . Is there a global search and replace to speed up the process of revising the code in the way you suggest? – WyoWindStorm Apr 9 at 15:48
  • @WyoWindStorm I don't understand your problem. Sorry. But if if you place the renew command in the preamble. Every question where you use solutionorbox, solution, solutionordottedlines environment, when you choose for the the print answer option, there will be no 'solution' word in your answer. – Arne Timperman Apr 11 at 15:46

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.