| … | |
… | |
| 25 | "PGchoicemacros.pl", |
25 | "PGchoicemacros.pl", |
| 26 | "PGanswermacros.pl", |
26 | "PGanswermacros.pl", |
| 27 | "PGauxiliaryFunctions.pl" |
27 | "PGauxiliaryFunctions.pl" |
| 28 | ); |
28 | ); |
| 29 | |
29 | |
| 30 | TEXT(&beginproblem); |
30 | TEXT(beginproblem()); |
| 31 | $showpartialcorrectanswers = 1; |
31 | $showpartialcorrectanswers = 1; |
| 32 | |
32 | |
| 33 | $a = random(2, 13, 1); |
33 | $a = random(2, 13, 1); |
| 34 | $b = random(2,7,1); |
34 | $b = random(2,7,1); |
| 35 | $c = random(2,7,1); |
35 | $c = random(2,7,1); |
| … | |
… | |
| 45 | $BR |
45 | $BR |
| 46 | $BR |
46 | $BR |
| 47 | EOT |
47 | EOT |
| 48 | |
48 | |
| 49 | $ans = (2*$a*($r1) + $b)*($c*(($r1)) - $d) + ($a*(($r1)**2) + $b*($r1))*($c); |
49 | $ans = (2*$a*($r1) + $b)*($c*(($r1)) - $d) + ($a*(($r1)**2) + $b*($r1))*($c); |
| 50 | &ANS(std_num_cmp($ans)); |
50 | ANS(num_cmp($ans)); |
| 51 | |
51 | |
| 52 | TEXT(EV2(<<EOT)); |
52 | TEXT(EV2(<<EOT)); |
| 53 | (B) \( f'($r2) \) = \{ ans_rule(40) \} |
53 | (B) \( f'($r2) \) = \{ ans_rule(40) \} |
| 54 | $BR |
54 | $BR |
| 55 | EOT |
55 | EOT |
| 56 | |
56 | |
| 57 | $ans = (2*$a*($r2) + $b)*($c*(($r2)) - $d) + ($a*(($r2)**2) + $b*($r2))*($c); |
57 | $ans = (2*$a*($r2) + $b)*($c*(($r2)) - $d) + ($a*(($r2)**2) + $b*($r2))*($c); |
| 58 | &ANS(std_num_cmp($ans)); |
58 | ANS(num_cmp($ans)); |
| 59 | |
59 | |
| 60 | ENDDOCUMENT(); |
60 | ENDDOCUMENT(); |