* Exercise sets
@ 2005-12-19 19:26 David Arnold
2005-12-19 22:10 ` Patrick Gundlach
2005-12-19 22:48 ` Willi Egger
0 siblings, 2 replies; 3+ messages in thread
From: David Arnold @ 2005-12-19 19:26 UTC (permalink / raw)
All,
I'd like to design an exercise environment that will keep both the
exercise and solution together. Something like:
\startExercise
Blah, blah, blah.
\startSolution
Blah, blah, blah
\stopSolution
\stopExercise
At a higher level, something with parts, like:
\startExercise
Blah, blah, blah, ...
\item Blah, blah, blah, ...
\startSolution
Blah, blah, blah, ..
\stopSolution
\item Blah, blah, blah, ...
\startSolution
Blah, blah, blah, ..
\stopSolution
\item Blah, blah, blah, ...
\startSolution
Blah, blah, blah, ..
\stopSolution
\stopExercise
I'd like the exercises to get typeset in place, but the even
solutions should go to the end of the text.
Has anyone done something similar in Context?
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: Exercise sets
2005-12-19 19:26 Exercise sets David Arnold
@ 2005-12-19 22:10 ` Patrick Gundlach
2005-12-19 22:48 ` Willi Egger
1 sibling, 0 replies; 3+ messages in thread
From: Patrick Gundlach @ 2005-12-19 22:10 UTC (permalink / raw)
Hello David,
I think this solution is from one of the ConTeXt pdfs. Or from the
mailinglist. Or....
--------------------------------------------------
\defineblock[question]
\defineblock[answer]
\defineenumeration[question][location=top,text=Frage]
\defineenumeration[answer][location=top,text=Antwort]
\hideblocks[answer]
\starttext
\beginquestion
\question Wieviel ist $4*5$?
\endquestion
\beginanswer
\answer $20$.
\endanswer
\beginquestion
\question Was macht $100 / 10$??
\endquestion
\beginanswer
\answer $10$
\endanswer
\subject{Abschnitt}
\useblocks[answer]
\stoptext
--------------------------------------------------
Patrick
--
ConTeXt wiki and more: http://contextgarden.net
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: Exercise sets
2005-12-19 19:26 Exercise sets David Arnold
2005-12-19 22:10 ` Patrick Gundlach
@ 2005-12-19 22:48 ` Willi Egger
1 sibling, 0 replies; 3+ messages in thread
From: Willi Egger @ 2005-12-19 22:48 UTC (permalink / raw)
Hi David,
the answer must be found in \defineenumeration[question][..] and
\defineenumeration[answer][...] further you can use the defineblock[...]
mechanism. Please refer to the cont-enp.pdf pages 262 ff.
Kind regards
Willi
David Arnold wrote:
> All,
>
> I'd like to design an exercise environment that will keep both the
> exercise and solution together. Something like:
>
> \startExercise
>
> Blah, blah, blah.
>
> \startSolution
> Blah, blah, blah
> \stopSolution
>
> \stopExercise
>
> At a higher level, something with parts, like:
>
> \startExercise
>
> Blah, blah, blah, ...
>
> \item Blah, blah, blah, ...
>
> \startSolution
> Blah, blah, blah, ..
> \stopSolution
>
>
> \item Blah, blah, blah, ...
>
> \startSolution
> Blah, blah, blah, ..
> \stopSolution
>
> \item Blah, blah, blah, ...
>
> \startSolution
> Blah, blah, blah, ..
> \stopSolution
>
> \stopExercise
>
> I'd like the exercises to get typeset in place, but the even
> solutions should go to the end of the text.
>
> Has anyone done something similar in Context?
> _______________________________________________
> ntg-context mailing list
> ntg-context@ntg.nl
> http://www.ntg.nl/mailman/listinfo/ntg-context
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2005-12-19 22:48 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-12-19 19:26 Exercise sets David Arnold
2005-12-19 22:10 ` Patrick Gundlach
2005-12-19 22:48 ` Willi Egger
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).