Parent Directory
|
Revision Log
Revision 823 - (view) (download)
| 1 : | apizer | 341 | #DESCRIPTION |
| 2 : | ## Algebra problem: function definition | ||
| 3 : | ##ENDDESCRIPTION | ||
| 4 : | |||
| 5 : | ##KEYWORDS('algebra', 'function', 'definition') | ||
| 6 : | |||
| 7 : | DOCUMENT(); # This should be the first executable line in the problem. | ||
| 8 : | |||
| 9 : | loadMacros( | ||
| 10 : | "PG.pl", | ||
| 11 : | "PGbasicmacros.pl", | ||
| 12 : | "PGchoicemacros.pl", | ||
| 13 : | "PGanswermacros.pl", | ||
| 14 : | "PGgraphmacros.pl" | ||
| 15 : | ); | ||
| 16 : | |||
| 17 : | TEXT(beginproblem()); | ||
| 18 : | |||
| 19 : | $showPartialCorrectAnswers = 1; | ||
| 20 : | |||
| 21 : | $a = random(2,25,1); | ||
| 22 : | $b = random(2,25,1); | ||
| 23 : | |||
| 24 : | BEGIN_TEXT | ||
| 25 : | Express the rule "Multiply by $a, then add $b" as the function | ||
| 26 : | $BR$BR | ||
| 27 : | \(f(x)=\) \{ans_rule(15)\}. | ||
| 28 : | $BR | ||
| 29 : | END_TEXT | ||
| 30 : | |||
| 31 : | $ans1 = "$a*x+$b"; | ||
| 32 : | |||
| 33 : | gage | 823 | ANS(fun_cmp($ans1)); |
| 34 : | apizer | 341 | |
| 35 : | ENDDOCUMENT(); # This should be the last executable line in the problem. | ||
| 36 : |
| aubreyja at gmail dot com | ViewVC Help |
| Powered by ViewVC 1.0.9 |