[npl] / trunk / NationalProblemLibrary / ASU-topics / set119LinearSystems / p9.pg Repository: Repository Listing bbplugincoursesdistsnplrochestersystemwww

# View of /trunk/NationalProblemLibrary/ASU-topics/set119LinearSystems/p9.pg

Sat Jan 14 02:13:08 2006 UTC (7 years, 4 months ago) by jj
File size: 980 byte(s)
```New problems for the library.
```

```    1 #DESCRIPTION
2 ##  Algebra problem:  Systems of equations
3 ##ENDDESCRIPTION
4
5 ##KEYWORDS('algebra', 'pair of lines', 'story question')
6
7 DOCUMENT();        # This should be the first executable line in the problem.
8
10 "PGasu.pl",
11 "PG.pl",
12 "PGbasicmacros.pl",
13 "PGchoicemacros.pl",
15 "PGauxiliaryFunctions.pl"
16 );
17
18 TEXT(beginproblem());
20 \$x=random(5,20,1);
21 \$y=random(5,20,1);
22 \$sum = 10*\$x + 25*\$y ;
23 \$value = \$sum/100;
24 \$ttl = \$x + \$y;
25
26 BEGIN_TEXT
27 A man has \$ttl coins in his pocket, all of which are dimes and quarters.
28 If the total value of his change is \$DOLLAR \{ sprintf("%.2f",\$value) \}, how many dimes and how
29 many quarters does he have?
30 \$BR
32 \$BR
33 Number of dimes equals \{ans_rule(25) \}
34 \$BR
35 Number of quarters equals \{ans_rule(25) \}
36 \$BR
37 END_TEXT
38
39 \$ans1 = \$x;
40 \$ans2 = \$y;
41
42 ANS(std_num_cmp(\$ans1));
43 ANS(std_num_cmp(\$ans2));
44
45 ENDDOCUMENT();        # This should be the last executable line in the problem.
46
```