NAME

PGmiscevaluators.pl - Some miscellaneous answer macros.

DESCRIPTION

Currently contains answer evaluators for radio buttons and checkboxes.

MathObjects and answer evaluators

The MathObjects system provides a parserRadioButtons.pl file that manages display and checking of radio-button based answers. It is recommended that you use this method directly if possible.

checkbox_cmp

ANS(checkbox_cmp($correctAnswer))

$correctAnswer is a string containing the names of the correct boxes, e.g. "ACD". Note that this means that individual checkbox names can only be one character. Internally, this is largely the same as unordered_cs_str_cmp().

radio_cmp

ANS(radio_cmp($correctAnswer))

$correctAnswer is a string containing the name of the correct radio button, e.g. "Choice1". This is case sensitive and whitespace sensitive, so the correct answer must match the name of the radio button exactly.

SEE ALSO

PGanswermacros.pl, UsingMathObjects.