[npl] / trunk / NationalProblemLibrary / Rochester / instructiveProblems / WeightedCreditAns.pg Repository:
ViewVC logotype

View of /trunk/NationalProblemLibrary/Rochester/instructiveProblems/WeightedCreditAns.pg

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1321 - (download) (annotate)
Fri Jun 18 02:17:13 2010 UTC (2 years, 11 months ago) by gage
File size: 1735 byte(s)
Adding missing files that were in the CVS version of NPL

    1 DOCUMENT();
    2 
    3 loadMacros("PGbasicmacros.pl",
    4            "PGchoicemacros.pl",
    5            "PGanswermacros.pl",
    6            "PGauxiliaryFunctions.pl",
    7            "PGgraphmacros.pl",
    8            "weightedGrader.pl"
    9           );
   10 
   11 install_weighted_grader();
   12 
   13 $showPartialCorrectAnswers = 1;
   14 
   15 TEXT(beginproblem());
   16 
   17 BEGIN_TEXT
   18 
   19 When you answer the questions sequentially, you get 20 percent partial credit for answering the first question correctly, 30 percent for answering the second question correctly, and 50 percent for answering the third question correctly.
   20 
   21 $PAR
   22 
   23 If you answer the third question correctly and leave the first two answers blank, you receive 100 percent credit.  If you answer the third question correctly but either of the first two answers are incorrect, you will only receive partial credit.
   24 
   25 $PAR
   26 
   27 What is the smallest prime number? \{NAMED_ANS_RULE('optional1',10)\}
   28 $BR
   29 What is the second smallest prime number? \{NAMED_ANS_RULE('optional2',10)\}
   30 $BR
   31 What is the third smallest prime number? \{ans_rule(10)\}
   32 $PAR
   33 ${BITALIC}Note: You can earn full credit by having the last question correct and having all other questions either blank or correct.${EITALIC}
   34 
   35 END_TEXT
   36 
   37 NAMED_WEIGHTED_ANS('optional1',std_num_cmp(2),20); # 20%
   38 NAMED_WEIGHTED_ANS('optional2',std_num_cmp(3),30); # 30%
   39 CREDIT_ANS(std_num_cmp(5),['optional1','optional2'],50); # 50% or full
   40 
   41 # If there was only one optional answer, or, if you want the
   42 # credit answer to provide credit only for the first optional
   43 # answer, use the following syntax.
   44 # (Remember to change the Note: to the students.)
   45 # CREDIT_ANS(std_num_cmp(5),'optional1',50); # 50% or full
   46 
   47 
   48 HINT(EV2(<<END_HINT));
   49 $HR
   50 ${BBOLD}Hint:${EBOLD}  This is a hint.
   51 END_HINT
   52 
   53 ENDDOCUMENT();

aubreyja at gmail dot com
ViewVC Help
Powered by ViewVC 1.0.9