# Perl Variables for Any Question Type

The following reserved Perl variables are used to return information or set behaviors in questions that you create in WebAssign.

These variables can be used in all questions.

Variable

Description

$ASSIGNMENT_ID Returns current assignment ID. $CORRECT

Returns true (1) if student's response is correct.

$DEPLOYMENT_ID Returns the unique identifier for this scheduled instance of this assignment. Not the same as the assignment ID. $EMAIL

Returns the email address of the student completing the question.

$FULLNAME Returns the full name of the student completing the question. $HINT

Set the hint to be displayed.

$CORRECT_HINT Set the hint to be displayed after a correct response. $HINT_ON_CORRECT

Set to displays available hints even when your student's response is correct.

$pi Returns a calculated value of pi. $POINTS

Returns point value of question part.

$QUESTION_ID Returns the current QID. $QUESTION_NUM

Returns current question number on assignment.

$RESPONSE_NUM Returns number of submissions made. $STUDENT

Returns unique ID of the student completing the question.

$THIS_SCORE Set to override question part score. $THISBOXNAME

Returns full name of answer box, for example, RN_355_1_0_83 is the box name for a random numerical box of question ID 355. It is the first part (0) of the first question (1) on the assignment and 83 is the random seed.

$thisresponse Returns student's response for the answer box. Important: Changing the value of this variable can cause your student's answer to be graded incorrectly. $TOOLTIP

In Answer, customizes or hides answer format tip for one answer box, for example, $TOOLTIP='Enter a whole number'. To hide the answer format tip for an answer box, set $TOOLTIP=' ' (with a space).