diff --git a/docs/en_us/course_authors/source/Images/NumericalInput_Complex.png b/docs/en_us/course_authors/source/Images/NumericalInput_Complex.png index 134f14bba4..d8a30d1039 100644 Binary files a/docs/en_us/course_authors/source/Images/NumericalInput_Complex.png and b/docs/en_us/course_authors/source/Images/NumericalInput_Complex.png differ diff --git a/docs/en_us/course_authors/source/Images/image292.png b/docs/en_us/course_authors/source/Images/image292.png index 58e119344a..eceeae7b03 100644 Binary files a/docs/en_us/course_authors/source/Images/image292.png and b/docs/en_us/course_authors/source/Images/image292.png differ diff --git a/docs/en_us/course_authors/source/additional_tools.rst b/docs/en_us/course_authors/source/additional_tools.rst index f014ad8c1d..18de2df3b0 100644 --- a/docs/en_us/course_authors/source/additional_tools.rst +++ b/docs/en_us/course_authors/source/additional_tools.rst @@ -13,14 +13,167 @@ Individual course teams frequently create tools and problem types that don't hav Below, we provide you with all the files and code that you need to create the following tools and problem types. -* :ref:`Gene Explorer` * :ref:`Chemical Equation` +* :ref:`Conditional Module` +* :ref:`Gene Explorer` * :ref:`Interactive Periodic Table` * :ref:`Molecule Editor` * :ref:`Multiple Choice and Numerical Input` * :ref:`Polls` * :ref:`Protein Builder` + +.. _Chemical Equation: + +************************** +Chemical Equation Problem +************************** + +The chemical equation problem type allows the student to enter text that represents a chemical equation into a text box. The LMS converts that text into a chemical equation below the text box. The grader evaluates the student's response by using a Python script that you create and embed in the problem. + +.. image:: /Images/ChemicalEquationExample.png + :alt: Image of a chemical equation response problem + +==================================== +Create the Chemical Equation Problem +==================================== + +Chemical equation problems use MathJax to create formulas. For more information about using MathJax in Studio, see :ref:`MathJax in Studio`. + +To create the above chemical equation problem: + +#. In the unit where you want to create the problem, click **Problem** under **Add New Component**, and then click the **Advanced** tab. +#. Click **Blank Advanced Problem**. +#. In the component that appears, click **Edit**. +#. In the component editor, paste the code from below. +#. Click **Save**. + + +Sample Chemical Equation Problem Code +------------------------------------- + +.. code-block:: xml + + + +

Some problems may ask for a particular chemical equation. Practice by writing out the following reaction in the box below.

+ + \( \text{H}_2\text{SO}_4 \longrightarrow \text { H}^+ + \text{ HSO}_4^-\) + + + + + + if chemcalc.chemical_equations_equal(submission[0], 'H2SO4 -> H^+ + HSO4^-'): + correct = ['correct'] + else: + correct = ['incorrect'] + + + +

Some tips:

+ + + + + +
+

Solution

+

To create this equation, enter the following:

+

H2SO4 -> H^+ + HSO4^-

+
+
+
+ +.. _Conditional Module: + +****************** +Conditional Module +****************** + +================== +Format description +================== + +The main tag of Conditional module input is: + +.. code-block:: xml + + ... + +``conditional`` can include any number of any xmodule tags (``html``, ``video``, ``poll``, etc.) or ``show`` tags. + +conditional tag +--------------- + +The main container for a single instance of Conditional module. The following attributes can +be specified for this tag:: + + sources - location id of required modules, separated by ';' + [message | ""] - message for case, where one or more are not passed. Here you can use variable {link}, which generate link to required module. + + [submitted] - map to `is_submitted` module method. + (pressing RESET button makes this function to return False.) + + [correct] - map to `is_correct` module method + [attempted] - map to `is_attempted` module method + [poll_answer] - map to `poll_answer` module attribute + [voted] - map to `voted` module attribute + +show tag +-------- + +Symlink to some set of xmodules. The following attributes can +be specified for this tag:: + + sources - location id of modules, separated by ';' + +======= +Example +======= + +Examples of conditional depends on poll +------------------------------------------- + +.. code-block:: xml + + + +

You see this, cause your vote value for "First question" was "man"

+ +
+ +Examples of conditional depends on poll (use tag) +-------------------------------------------------------- + +.. code-block:: xml + + + + + + + +Examples of conditional depends on problem +------------------------------------------- + +.. code-block:: xml + + + You see this, cause "lec27_Q1" is attempted. + + + You see this, cause "lec27_Q1" is not attempted. + + + .. _Gene Explorer: ************************** @@ -72,76 +225,6 @@ In this code: * **genex_problem_number** specifies the number of the problem. This number is based on the five gene editor problems in the MITx 7.00x course--for example, if you want this problem to look like the second gene editor problem in the 7.00x course, you would set the **genex_problem_number** value to 2. The number must be 1, 2, 3, 4, or 5. -.. _Chemical Equation: - -************************** -Chemical Equation Problem -************************** - -The chemical equation problem type allows the student to enter chemical equations. The grader evaluates student responses by using a Python script that you create and embed in the problem. - -.. image:: /Images/ChemicalEquationExample.png - :alt: Image of a chemical equation response problem - -==================================== -Create the Chemical Equation Problem -==================================== - -To create the above chemical equation problem: - -#. In the unit where you want to create the problem, click **Problem** under **Add New Component**, and then click the **Advanced** tab. -#. Click **Blank Advanced Problem**. -#. In the component that appears, click **Edit**. -#. In the component editor, paste the code from below. -#. Click **Save**. - - - - - -==================================== -Chemical Equation Problem Code -==================================== - -.. code-block:: xml - - - -

Some problems may ask for a particular chemical equation. Practice by writing out the following reaction in the box below.

- - \( \text{H}_2\text{SO}_4 \longrightarrow \text { H}^+ + \text{ HSO}_4^-\) - - - - - - if chemcalc.chemical_equations_equal(submission[0], 'H2SO4 -> H^+ + HSO4^-'): - correct = ['correct'] - else: - correct = ['incorrect'] - - - -

Some tips:

-
    -
  • Use real element symbols.
  • -
  • Create subscripts by using plain text.
  • -
  • Create superscripts by using a caret (^).
  • -
  • Create the reaction arrow (\(\longrightarrow\)) by using "->".
  • -
- - - - -
-

Solution

-

To create this equation, enter the following:

-

H2SO4 -> H^+ + HSO4^-

-
-
-
- - .. _Interactive Periodic Table: ************************** @@ -494,6 +577,68 @@ Create a Poll * A .csv file that contains student responses to the problem is not currently available for polls. However, you can obtain the aggregate data directly in the problem. +================== +Format description +================== + +The main tag of Poll module input is: + +.. code-block:: xml + + ... + +``poll_question`` can include any number of the following tags: +any xml and ``answer`` tag. All inner xml, except for ``answer`` tags, we call "question". + +poll_question tag +----------------- + +Xmodule for creating poll functionality - voting system. The following attributes can +be specified for this tag:: + + name - Name of xmodule. + [display_name| AUTOGENERATE] - Display name of xmodule. When this attribute is not defined - display name autogenerate with some hash. + [reset | False] - Can reset/revote many time (value = True/False) + + +answer tag +---------- + +Define one of the possible answer for poll module. The following attributes can +be specified for this tag:: + + id - unique identifier (using to identify the different answers) + +Inner text - Display text for answer choice. + +Example +======= + +Examples of poll +---------------- + +.. code-block:: xml + + +

Age

+

How old are you?

+ < 18 + from 10 to 25 + > 25 +
+ +Examples of poll with unable reset functionality +------------------------------------------------ + +.. code-block:: xml + + +

Your gender

+

You are man or woman?

+ Man + Woman +
.. _Protein Builder: diff --git a/docs/en_us/course_authors/source/advanced_problems.rst b/docs/en_us/course_authors/source/advanced_problems.rst index 8c5d76c33e..d0c67ade6b 100644 --- a/docs/en_us/course_authors/source/advanced_problems.rst +++ b/docs/en_us/course_authors/source/advanced_problems.rst @@ -9,7 +9,6 @@ Advanced tab when you create a new Problem component. Studio provides templates for these problems, but the problems open directly in the **Advanced Editor** and have to be created in XML. -- :ref:`Chemical Equation` In chemical equation problems, students enter text that represents a chemical equation into a text box. - :ref:`Circuit Schematic Builder` In circuit schematic problems, students create and modify circuits on an interactive grid and submit computer-generated analyses of the circuits for grading. @@ -33,104 +32,6 @@ These problems are easy to access in Studio. To create them, click **Problem** under **Add New Component**, click the **Advanced** tab, and then click the name of the problem that you want to create. -To add a label for an advanced problem, you'll add a **label** attribute to one of the XML tags for the problem. For more information, see :ref:`Appendix E`. - -.. _Chemical Equation Input: - -Chemical Equation ------------------ - -In chemical equation problems, students enter text that represents a chemical equation into a text box. The LMS converts that text into a chemical equation below the text box. - -**Sample Problem** - -.. image:: /Images/ChemicalEquationExample.png - :alt: Image of a chemical equation problem - -**Required Tags** - -.. list-table:: - :widths: 20 80 - - * - ```` - - Indicates that this problem has a custom response. The ```` tags must surround the ```` tags. - * - ```` - - A child of ````. Indicates that the answer to this problem is a chemical equation. Must contain the ``size`` and ``label`` attributes. - * - ```` - - A child of ````. Contains the Python script that grades the problem. - -Chemical equation problems use MathJax to create formulas. For more information about using MathJax in Studio, see :ref:`MathJax in Studio`. - -**Sample Problem XML**: - -.. code-block:: xml - - - -

Some problems may ask for a particular chemical equation. Practice by writing out the following reaction in the box below.

- - \( \text{H}_2\text{SO}_4 \longrightarrow \text { H}^+ + \text{ HSO}_4^-\) - - - - - - if chemcalc.chemical_equations_equal(submission[0], 'H2SO4 -> H^+ + HSO4^-'): - correct = ['correct'] - else: - correct = ['incorrect'] - - - -

Some tips:

-
    -
  • Use real element symbols.
  • -
  • Create subscripts by using plain text.
  • -
  • Create superscripts by using a caret (^).
  • -
  • Create the reaction arrow (\(\longrightarrow\)) by using "->".
  • -
- - - - -
-

Solution

-

To create this equation, enter the following:

-

H2SO4 -> H^+ + HSO4^-

-
-
-
- -**Problem Template**: - -.. code-block:: xml - - - -

Problem text

- - - - - - if chemcalc.chemical_equations_equal(submission[0], 'TEXT REPRESENTING CHEMICAL EQUATION'): - correct = ['correct'] - else: - correct = ['incorrect'] - - - - - - - -
-

Solution or Explanation Header

-

Solution or explanation text

-
-
-
- .. _Circuit Schematic Builder: @@ -155,31 +56,32 @@ Create a Circuit Schematic Builder Problem #. In the component editor, replace the example code with your own code. #. Click **Save**. -**Problem Code**: +**Problem Code** + +To create the problem in the picture, paste the following code into the Advanced Editor. .. code-block:: xml - - -

Make a voltage divider that splits the provided voltage evenly.

- -
- -
- - dc_value = "dc analysis not found" - for response in submission[0]: - if response[0] == 'dc': - for node in response[1:]: - dc_value = node['output'] - if dc_value == .5: - correct = ['correct'] - else: - correct = ['incorrect'] - -
+ +

Make a voltage divider that splits the provided voltage evenly.

+ +
+ +
+ + dc_value = "dc analysis not found" + for response in submission[0]: + if response[0] == 'dc': + for node in response[1:]: + dc_value = node['output'] + if dc_value == .5: + correct = ['correct'] + else: + correct = ['incorrect'] + +

Make a high pass filter.

@@ -211,15 +113,15 @@ Create a Circuit Schematic Builder Problem

- + .. _Custom JavaScript Display and Grading: Custom JavaScript Display and Grading ------------------------------------- -Custom JavaScript display and grading problems (also called custom JavaScript problems -or JS Input problems) allow you to create a custom problem or tool that uses JavaScript +Custom JavaScript display and grading problems (also called *custom JavaScript problems* +or *JS Input problems*) allow you to create a custom problem or tool that uses JavaScript and then add the problem or tool directly into Studio. When you create a JS Input problem, Studio embeds the problem in an inline frame (IFrame) so that your students can interact with it in the LMS. You can grade your students’ work using JavaScript and some basic Python, and @@ -269,25 +171,12 @@ To re-create the example problem above, you'll need the following files. - webGLDemo.css - three.min.js -You'll create the first three files using the code in :ref:`Appendix F`. The three.min.js file is a library -file that you'll download. +To download these files in a .zip archive, go to http://files.edx.org/JSInput.zip. -#. Go to :ref:`Appendix F` and use the code samples to create the following files. +..note:: If you need to bypass the SOP, you'll also need the **jschannel.js** file, and your webGLDemo.html file will be slightly different. To download all these files in a .zip archive, go to http://files.edx.org/JSInput_BypassSOP.zip. - - webGLDemo.html - - webGLDemo.js - - webGLDemo.css - -#. Download the **three.min.js** file. To do this, go to the `three.js home page `_, - and then click **Download** in - the left pane. After the .zip file has finished downloading, open the .zip file, and then - open the **build** folder to access the three.min.js file. - - **Note** If you need to bypass the SOP, you'll also need the **jschannel.js** file. To do - this, go to the `jschannel.js `_ - page, copy the code for the file into a text editor, and then save the file as jschannel.js. - -#. On the **Files & Uploads** page, upload all the files you just created or downloaded. +#. Download and unpackage the files in either the JSInput.zip file or the JSInput_BypassSOP.zip file. +#. On the **Files & Uploads** page, upload all the files from the .zip file. #. Create a new custom JavaScript display and grading problem component. #. On the **Settings** tab, set **Maximum Attempts** to a number larger than zero. @@ -295,9 +184,9 @@ file that you'll download. #. Click **Save.** JavaScript Input Problem Code -############################# +^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ -:: +.. code-block:: xml In the image below, click the cone. @@ -336,21 +225,19 @@ JavaScript Input Problem Code .. note:: When you create this problem, keep the following in mind. - - The webGLDemo.js file defines the three JavaScript functions (**WebGLDemo.getGrade**, **WebGLDemo.getState**, and **WebGLDemo.setState**). + - The webGLDemo.js file defines the three JavaScript functions (**WebGLDemo.getGrade**, **WebGLDemo.getState**, and **WebGLDemo.setState**). - - The JavaScript input problem code uses **WebGLDemo.getGrade**, **WebGLDemo.getState**, and **WebGLDemo.setState** to grade, save, or restore a problem. These functions must be global in scope. + - The JavaScript input problem code uses **WebGLDemo.getGrade**, **WebGLDemo.getState**, and **WebGLDemo.setState** to grade, save, or restore a problem. These functions must be global in scope. - - **WebGLDemo.getState** and **WebGLDemo.setState** are optional. You only have to define these functions if you want to conserve the state of the problem. + - **WebGLDemo.getState** and **WebGLDemo.setState** are optional. You only have to define these functions if you want to conserve the state of the problem. - - **Width** and **height** represent the dimensions of the IFrame that holds the application. + - **Width** and **height** represent the dimensions of the IFrame that holds the application. - - When the problem opens, the cone and the cube are both blue, or "unselected." When you click either shape once, the shape becomes yellow, or "selected." To unselect the shape, click it again. Continue clicking the shape to select and unselect it. - - - The response is graded as correct if the cone is selected (yellow) when the user clicks **Check**. - - - Clicking **Check** or **Save** registers the problem's current state. + - When the problem opens, the cone and the cube are both blue, or "unselected." When you click either shape once, the shape becomes yellow, or "selected." To unselect the shape, click it again. Continue clicking the shape to select and unselect it. + - The response is graded as correct if the cone is selected (yellow) when the user clicks **Check**. + - Clicking **Check** or **Save** registers the problem's current state. .. _Custom Python Evaluated Input: @@ -358,27 +245,190 @@ Custom Python-Evaluated Input ("Write-Your-Own-Grader") ------------------------------------------------------- -In custom Python-evaluated input (also called "write-your-own-grader problems" problems), the grader evaluates a student's response using a Python script that you create and embed in the problem. These problems can be any type. Numerical input and text input problems are the most popular write-your-own-grader problems. +In custom Python-evaluated input (also called "write-your-own-grader problems" problems), the grader uses a Python script that you create and embed in the problem to evaluates a student's response or provide hints. These problems can be any type. Numerical input and text input problems are the most popular write-your-own-grader problems. .. image:: Images/CustomPythonExample.png :alt: Image of a write your own grader problem -Create a Write-Your-Own-Grader Problem -~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +Custom Python-evaluated input problems can include the following: -To create a write-your-own-grader problem: +* :ref:`Chemical Equation` +* :ref:`Custom JavaScript Display and Grading` +* :ref:`Custom Python Evaluated Input` +* :ref:`Gene Explorer` +* :ref:`Molecule Editor` +* :ref:`Protein Builder` + +.. list-table:: + :widths: 20 80 + + * - `` + +

Enter two integers that sum to 10.

+ +
+
@@ -464,7 +513,6 @@ The following template does not return answers when the student clicks **Show An return (a1+a2)== float(expect) -

Enter two real numbers that sum to 20:


@@ -479,6 +527,7 @@ The following template does not return answers when the student clicks **Show An
+ .. _Drag and Drop: Drag and Drop @@ -493,18 +542,50 @@ text or objects to a specific location on an image. Create a Drag and Drop Problem ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -To create a drag and drop problem: +To create a drag and drop problem, you'll need the following files: -#. In the unit where you want to create the problem, click **Problem** - under **Add New Component**, and then click the **Advanced** tab. +* Allopurinol.gif +* AllopurinolAnswer.gif + +To download both these files in a .zip archive, go to http://files.edx.org/DragAndDropProblemFiles.zip. + +To create the molecule editor that appears in the image above, you'll upload the files for this problem, and then paste the code below into a Problem component. + +#. Upload the Allopurinol.gif and AllopurinolAnswer.gif files to the **Files & Uploads** page. +#. In the unit where you want to create the problem, click **Problem** under **Add New Component**, and then click the **Advanced** tab. #. Click **Drag and Drop**. #. In the component that appears, click **Edit**. -#. In the component editor, replace the example code with your own code. +#. In the component editor, replace the example code with the following code. #. Click **Save**. +**Problem Code**: + +.. code-block:: xml + + +

Allopurinol is a drug used to treat and prevent gout, a very painful form of arthritis. Once only a “rich man’s disease”, gout has become more and more common in recent decades – affecting about 3 million people in the United States alone. Deposits of needle-like crystals of uric acid in connective tissue or joint spaces cause the symptoms of swelling, stiffness and intense pain. Individuals with gout overproduce uric acid because they cannot eliminate it efficiently. Allopurinol treats and prevents gout by stopping the overproduction of uric acid through inhibition of an enzyme required for the synthesis of uric acid.

+

You are shown one of many possible molecules. On the structure of allopurinol below, identify the functional groups that are present by dragging the functional group name listed onto the appropriate target boxes on the structure. If you want to change an answer, you have to drag off the name as well. You may need to scroll through the names of functional groups to see all options.

+ + + + + + + + + + + + + + + correct_answer = [ {'draggables': ['2'], 'targets': ['0' ], 'rule':'unordered_equal' }, {'draggables': ['none'], 'targets': ['1' ], 'rule':'unordered_equal' }] if draganddrop.grade(submission[0], correct_answer): correct = ['correct'] else: correct = ['incorrect'] + + + + +
-For more information about drag and drop problems, see `XML Format of Drag and Drop Input -`_. .. _Image Mapped Input: @@ -515,7 +596,7 @@ In an image mapped input problem, students click inside a defined area in an image. You define this area by including coordinates in the body of the problem. -.. image:: Images/ImageMappedInputExample.gif +.. image:: Images/image294.png :alt: Image of an image mapped input problem Create an Image Mapped Input Problem @@ -544,18 +625,7 @@ To create a image mapped input problem: -**Problem Template** -.. code-block:: xml - - - -

In the image below, click the triangle.

- - - - -
.. _Math Expression Input: @@ -573,6 +643,54 @@ Unlike numerical input problems, which only allow integers and a few select cons When you create a math expression input problem in Studio, you'll use `MathJax `_ to change your plain text into "beautiful math." For more information about how to use MathJax in Studio, see :ref:`MathJax in Studio`. + + +Create a Math Expression Input Problem +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +To create a math expression input problem: + +#. In the unit where you want to create the problem, click **Problem** + under **Add New Component**, and then click the **Advanced** tab. +#. Click **Math Expression Input**. +#. In the component that appears, click **Edit**. +#. In the component editor, replace the example code with your own code. +#. Click **Save**. + +**Problem Code** + +.. code-block:: xml + + +

Some problems may ask for a mathematical expression. Practice creating mathematical expressions by answering the questions below.

+ +

Write an expression for the product of R_1, R_2, and the inverse of R_3.

+ + + + + + + +

Let x be a variable, and let n be an arbitrary constant. What is the derivative of xn?

+ + + + + + + +
+

Explanation or Solution Header

+

Explanation or solution text

+
+
+
+ **Notes for Students** When you answer a math expression input problem, follow these guidelines. @@ -620,91 +738,6 @@ The LMS automatically converts the following Greek letter names into the corresp note:: ``epsilon`` is the lunate version, whereas ``varepsilon`` looks like a backward 3. -Create a Math Expression Input Problem -~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -To create a math expression input problem: - -#. In the unit where you want to create the problem, click **Problem** - under **Add New Component**, and then click the **Advanced** tab. -#. Click **Math Expression Input**. -#. In the component that appears, click **Edit**. -#. In the component editor, replace the example code with your own code. -#. Click **Save**. - -.. list-table:: - :widths: 20 80 - :header-rows: 1 - - * - ```` - - - * - ```` - - This tag includes the ``size`` and ``label`` attributes. - * - `` - -

Let x be a variable, and let n be an arbitrary constant. What is the derivative of xn?

- - - - - - - -
-

Explanation or Solution Header

-

Explanation or solution text

-
-
- - -**Template XML** - -.. code-block:: xml - - -

Problem text

- - - - - - - - -
-

Explanation or Solution Header

-

Explanation or solution text

-
-
-
- - - -For more information, see `Symbolic Response -`_. - .. _Problem with Adaptive Hint: Problem with Adaptive Hint diff --git a/docs/en_us/course_authors/source/appendices/e.rst b/docs/en_us/course_authors/source/appendices/e.rst index 0fa3bedc7b..1a6fe478db 100644 --- a/docs/en_us/course_authors/source/appendices/e.rst +++ b/docs/en_us/course_authors/source/appendices/e.rst @@ -1,30 +1,29 @@ .. _Appendix E: - -^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ +################################ APPENDIX E: Problem and Tool XML -^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ +################################ -This appendix provides information about the XML for most problem and tool types in Studio: +This appendix provides information about the XML tags for most problem and tool types in Studio: * :ref:`General` -* :ref:`Choice Response` -* :ref:`Chemical Equation Input` -* :ref:`Custom Response` -* :ref:`Formula Response` -* :ref:`Image Response` -* :ref:`Multiple Choice Response` -* :ref:`Numerical Response` -* :ref:`Option Response` -* :ref:`Schematic Response` -* :ref:`String Response` - +* :ref:`Checkbox Problem XML` +* :ref:`Chemical Equation Problem XML` +* :ref:`Drag and Drop Problem XML` +* :ref:`Dropdown Problem XML` +* :ref:`Image Mapped Input Problem XML` +* :ref:`JS Input Problem XML` +* :ref:`Multiple Choice Problem XML` +* :ref:`Numerical Input Problem XML` +* :ref:`Math Expression Input Problem XML` +* :ref:`Text Input Problem XML` .. _General: +======= General -------- +======= Most problems have the following tags. @@ -32,8 +31,7 @@ Most problems have the following tags. :widths: 20 80 * - `` `` - - These must be the first and last tags for any content created in the Advanced - Editor in a Problem component. + - These must be the first and last tags for any content created in the Advanced Editor in a Problem component. * - ```` - The ```` tag indicates the beginning of a line or block of text. * - ```` @@ -42,70 +40,17 @@ Most problems have the following tags. - If you want to include more information in the problem, such as a detailed explanation of the problem's answer, you'll enter the text between the two ``
`` tags, which are inside the ```` tags. (These tags do not have to be on the same line.) Additionally, all problems must include a **label** attribute. This attribute adds a descriptive label that helps visually impaired students navigate through the problem. + You'll add a **label** attribute to one of the XML tags for the problem. Each example problem below includes a label. -.. _Choice Response: +.. _Checkbox Problem XML: -Choice Response (Checkbox Problems) ------------------------------------ +============================= +Checkbox Problem XML +============================= -Although you can create checkbox problems by using the Simple Editor in Studio, you may want to see or change the problem's underlying XML. - -**Sample Problem** - -.. image:: ../Images/CheckboxExample.gif - :alt: Image of a checkbox problem - -**Tags** - -.. list-table:: - :widths: 20 80 - - * - ```` - - Specifies that the problem lists answer options for students to choose from. - * - ```` - - A child of ````. Specifies that the problem is a checkbox problem. Can include a ``direction`` attribute and a ``label`` attribute. - * - ```` - - A child of ````. Designates an answer option. Each choice must include the ``correct`` attribute, set to ``true`` (for a correct answer) or ``false`` (for an incorrect answer). For checkbox problems, more than one option can be a correct answer. - -**Sample Problem XML** - -.. code-block:: xml - - - -

Learning about the benefits of preventative healthcare can be particularly - difficult. Check all of the reasons below why this may be the case.

- - - - A large amount of time passes between undertaking - a preventative measure and seeing the result. - Non-immunized people will always fall sick. - - If others are immunized, fewer people will fall - sick regardless of a particular individual's choice to get immunized or not. - - Trust in healthcare professionals and government - officials is fragile. - - - -
-

Explanation

-

People who are not immunized against a disease may still not fall sick from the - disease. If someone is trying to learn whether or not preventative measures - against the disease have any impact, he or she may see these people and conclude, - since they have remained healthy despite not being immunized, that immunizations - have no effect. Consequently, he or she would tend to believe that immunization - (or other preventative measures) have fewer benefits than they actually do.

-
-
-
-
- - -**Template** +Template +-------- .. code-block:: xml @@ -130,73 +75,74 @@ Although you can create checkbox problems by using the Simple Editor in Studio,
-.. _Chemical Equation Input: +Tags +---- -Chemical Equation Input (Chemical Equation Problems) ----------------------------------------------------- +* ```` (required): Specifies that the problem contains options for students to choose from. +* ```` (required): Specifies that the problem is a checkbox problem. +* ```` (required): Designates an answer option. -In chemical equation problems, students enter text that represents a chemical equation into a text box. The LMS converts that text into a chemical equation below the text box. +**Tag:** ```` -**Sample Problem** +Specifies that the problem contains options for students to choose from. -.. image:: ../Images/ChemicalEquationExample.png - :alt: Image of a chemical equation response problem + Attributes -**Required Tags** + (none) -.. list-table:: - :widths: 20 80 + Children - * - ```` - - Indicates that this problem has a custom response. The ```` tags must surround the ```` tags. - * - ```` - - A child of ````. Indicates that the answer to this problem is a chemical equation. Must contain the ``size`` and ``label`` attributes. - * - ```` - - A child of ````. Contains the Python script that grades the problem. + * ```` -Chemical equation problems use MathJax to create formulas. For more information about using MathJax in Studio, see :ref:`MathJax in Studio`. +**Tag:** ```` -**Sample Problem XML**: +Specifies that the problem is a checkbox problem. -.. code-block:: xml + Attributes - - -

Some problems may ask for a particular chemical equation. Practice by writing out the following reaction in the box below.

- - \( \text{H}_2\text{SO}_4 \longrightarrow \text { H}^+ + \text{ HSO}_4^-\) + .. list-table:: + :widths: 20 80 - - - + * - Attribute + - Description + * - direction (optional) + - Specifies the orientation of the list of answers. The default is vertical. + * - label (required) + - Specifies the name of the response field. - if chemcalc.chemical_equations_equal(submission[0], 'H2SO4 -> H^+ + HSO4^-'): - correct = ['correct'] - else: - correct = ['incorrect'] + Children - - -

Some tips:

-
    -
  • Use real element symbols.
  • -
  • Create subscripts by using plain text.
  • -
  • Create superscripts by using a caret (^).
  • -
  • Create the reaction arrow (\(\longrightarrow\)) by using "->".
  • -
+ * ```` - +**Tag:** ```` + +Designates an answer option. + + Attributes + + .. list-table:: + :widths: 20 80 + + * - Attribute + - Description + * - true (at least one required) + - Indicates a correct answer. For checkbox problems, one or more ```` tags can contain a correct answer. + * - false (at least one required) + - Indicates an incorrect answer. + + Children - -
-

Solution

-

To create this equation, enter the following:

-

H2SO4 -> H^+ + HSO4^-

-
-
-
+ (none) -**Problem Template**: + +.. _Chemical Equation Problem XML: + +============================= +Chemical Equation Problem XML +============================= + +Template +-------- .. code-block:: xml @@ -205,7 +151,7 @@ Chemical equation problems use MathJax to create formulas. For more information

Problem text

- + if chemcalc.chemical_equations_equal(submission[0], 'TEXT REPRESENTING CHEMICAL EQUATION'): @@ -226,740 +172,192 @@ Chemical equation problems use MathJax to create formulas. For more information
+Tags +---- +* ````: Indicates that this problem has a custom response. +* ````: Specifies that the answer to this problem is a chemical equation. +* ````: Contains the Python script that grades the problem. -.. _Custom Response: +**Tag:** ```` -Custom Response ("Custom Python-Evaluated Input") Problems ------------------------------------------------------------ +Indicates that this problem has a custom response. The ```` tags must surround the ```` tags. -In custom Python-evaluated input (also called “write-your-own-grader”) problems, the grader evaluates a student’s response using a Python script that you create and embed in the problem. + Attributes -**Sample Problem** + (none) -.. image:: ../Images/CustomPythonExample.png - :alt: Image of a custom response problem + Children -.. list-table:: - :widths: 20 80 + * ```` + * ```` - * - `` +Contains the Python script that grades the problem. -

Part 1: Enter two integers that sum to 10.

- -
- -
+ Attributes -

Part 2: Enter two integers that sum to 20.

- -
- -
+ .. list-table:: + :widths: 20 80 - -
-

Explanation

-

For part 1, any two numbers of the form n and 10-n, where n is any integer, will work. One possible answer would be the pair 0 and 10.

-

For part 2, any pair x and 20-x will work, where x is any real number with a finite decimal representation. Both inputs have to be entered either in standard decimal notation or in scientific exponential notation. One possible answer would be the pair 0.5 and 19.5. Another way to write this would be 5e-1 and 1.95e1.

-
-
- + * - Attribute + - Description + * - type (required) + - Must be "loncapa/python". -**Templates** + Children + + (none) + -The following template includes answers that appear when the student clicks **Show Answer**. +.. _Drag and Drop Problem XML: -.. code-block:: xml +========================= +Drag and Drop Problem XML +========================= - - - - - -

Problem text

- -
- -
- - -
-

Solution or Explanation Heading

-

Solution or explanation text

-
-
-
- -The following template does not return answers when the student clicks **Show Answer**. If your problem doesn't include answers for the student to see, make sure to set **Show Answer** to **Never** in the problem component. - -.. code-block:: xml - - - - - - -

Enter two real numbers that sum to 20:

- -
- -
- - -
-

Solution or Explanation Heading

-

Solution or explanation text

-
-
-
- -.. _Formula Response: - -Formula Response (Math Expression Input Problems) -------------------------------------------------- - -**Sample Problem** - -.. image:: ../Images/MathExpressionInputExample.gif - :alt: Image of a math expression input problem - -.. list-table:: - :widths: 20 80 - :header-rows: 1 - - * - ```` - - - * - ```` - - This tag includes the ``size`` and ``label`` attributes. - * - `` - -

Let x be a variable, and let n be an arbitrary constant. What is the derivative of xn?

- - - - - - - -
-

Explanation or Solution Header

-

Explanation or solution text

-
-
- - -**Template XML** +Template +-------- .. code-block:: xml

Problem text

- - - - - - - + + + + + + + + correct_answer = [ {'draggables': ['2'], 'targets': ['0' ], 'rule':'unordered_equal' }, {'draggables': ['none'], 'targets': ['1' ], 'rule':'unordered_equal' }] if draganddrop.grade(submission[0], correct_answer): correct = ['correct'] else: correct = ['incorrect'] + -
-

Explanation or Solution Header

-

Explanation or solution text

-
+
+Tags +---- -**XML Attribute Information** +* ````: Indicates the problem is a drag and drop problem. +* ````: Specifies a single object that a student will drag onto the base image. +* ````: Specifies the location on the base image where a draggable must be dropped. - - -

What is the distance in the plane between the points (pi, 0) and (0, e)? You can type math. - - - - -

- -
-

Explanation

-

The decimal numerical system is base ten.

-

The standard gravity constant is defined to be precisely 9.80665 m/s2. - This is 9.80 to two decimal places. Entering 9.8 also works.

-

By the distance formula, the distance between two points in the plane is - the square root of the sum of the squares of the differences of each coordinate. - Even though an exact numerical value is checked in this case, the - easiest way to enter this answer is to type - sqrt(pi^2+e^2) into the editor. - Other answers like sqrt((pi-0)^2+(0-e)^2) also work. -

-
-
- - -**Templates** - -Exact values - -.. code-block:: xml - - - - - - - - -
- -
-
-
- -Answers with decimal precision - -.. code-block:: xml - - - - - - - - - -
- -
-
-
- -Answers with percentage precision - -.. code-block:: xml - - - - - - - - - -
- -
-
-
- -Answers with scripts - -.. code-block:: xml - - - - - - - - - - - - -
- -
-
-
- - -**XML Attribute Information** - - + + + + + +The accepted attributes are: + +============== ============== ========= ========== +Attribute Name Value Type Required Default +============== ============== ========= ========== +html_file URL string Yes None +gradefn Function name Yes `gradefn` +set_statefn Function name No None +get_statefn Function name No None +height Integer No `500` +width Integer No `400` +============== ============== ========= ========== + + +Required Attributes +------------------- + +* **html_file** + + The **html_file** attribute specifies the HTML file that the IFrame will point to. The HTML file + must be located in the content directory. + + The IFrame is created using the sandbox attribute. Although pop-ups, scripts, and pointer locks are allowed, the IFrame cannot access its parent's attributes. + + The HTML file must contain a **gradefn** function that the JSInput file can access. To determine whether the **gradefn** function is accessible, in the console, make sure that **gradefn** returns the right thing. When JSInput uses the **gradefn** function, `gradefn` is called with `gradefn`.call(`obj`), where **obj** is the object-part of **gradefn**. For example, if **gradefn** is **myprog.myfn**, JSInput calls **myprog.myfun.call(myprog)**. (This is to ensure "`this`" continues to refer to what `gradefn` expects.) + + Aside from that, more or less anything goes. Note that currently there is no support for inheriting CSS or JavaScript from the parent (aside from the Chrome-only **seamless** attribute, which is set to True by default). + +* **gradefn** + + The **gradefn** attribute specifies the name of the function that will be called when a user clicks **Check**, and that returns the student's answer. Unless both the **get_statefn** and **set_statefn** attributes are also used, this answer is passed as a string to the enclosing response type. In the **customresponse** example above, this means **cfn** will be passed this answer as ``ans``. + + If the **gradefn** function throws an exception when a student attempts to submit a problem, the submission is aborted, and the student receives a generic alert. The alert can be customised by making the exception name ``Waitfor Exception``; in that case, the alert message will be the exception message. + + .. important:: To make sure the student's latest answer is passed correctly, make sure that the **gradefn** function is not asynchronous. Additionally, make sure that the function returns promptly. Currently the student has no indication that her answer is being calculated or produced. + +Optional Attributes +------------------- + +* **set_statefn** + + Sometimes a problem author will want information about a student's previous answers ("state") to be saved and reloaded. If the attribute **set_statefn** is used, the function given as its value will be passed the state as a string argument whenever there is a state, and the student returns to a problem. The function has the responsibility to then use this state approriately. + + The state that is passed is: + + * The previous output of **gradefn** (i.e., the previous answer) if **get_statefn** is not defined. + * The previous output of **get_statefn** (see below) otherwise. + + It is the responsibility of the iframe to do proper verification of the argument that it receives via **set_statefn**. + +* **get_statefn** + + Sometimes the state and the answer are quite different. For instance, a problem that involves using a javascript program that allows the student to alter a molecule may grade based on the molecule's hydrophobicity, but from the hydrophobicity it might be incapable of restoring the state. In that case, a + *separate* state may be stored and loaded by **set_statefn**. Note that if **get_statefn** is defined, the answer (i.e., what is passed to the enclosing response type) will be a json string with the following format: + + .. code-block:: xml + + { + answer: `[answer string]` + state: `[state string]` + } + + + The enclosing response type must then parse this as json. + +* **height** and **width** + + The **height** and **width** attributes are straightforward: they specify the height and width of the IFrame. Both are limited by the enclosing DOM elements, so for instance there is an implicit max-width of around 900. + + In the future, JSInput may attempt to make these dimensions match the HTML file's dimensions (up to the aforementioned limits), but currently it defaults to `500` and `400` for **height** and **width**, respectively. + +.. _Multiple Choice Problem XML: + +============================= +Multiple Choice Problem XML +============================= + +Template +-------- + +.. code-block:: xml + + +

Question text

+ + + Incorrect choice + Correct choice + + +
-

Explanation

-

The correct answer is herd immunity. As more and more people use bednets, the risk of malaria begins to fall for everyone – users and non-users alike. This can fall to such a low probability that malaria is effectively eradicated from the group (even when the group does not have 100% bednet coverage).

+

Explanation or solution header

+

Explanation or solution text

-**Template** +Tags +---- + +* ```` (required): Indicates that the problem is a multiple choice problem. +* ```` (required): Indicates the beginning of the list of options. +* ```` (required): Lists an answer option. + +**Tag:** ```` + +Indicates that the problem is a multiple choice problem. + + Attributes + + (none) + + Children + + * ```` + * All standard HTML tags (can be used to format text) + +**Tag:** ```` + +Indicates the beginning of the list of options. + + Attributes + + .. list-table:: + :widths: 20 80 + + * - Attribute + - Description + * - label (required) + - Specifies the name of the response field. + * - type (required) + - Must be set to "MultipleChoice". + + Children + + * ```` + +**Tag:** ```` + +Lists an answer option. + + Attributes + + .. list-table:: + :widths: 20 80 + + * - Attribute + - Description + * - correct (at least one required) + - Indicates a correct or incorrect answer. When the attribute is set to "true", the choice is a correct answer. When the attribute is set to "false", the choice is an incorrect answer. Only one choice can be a correct answer. + * - name + - A unique name that the back end uses to refer to the choice. + + Children + + (none) + +.. _Numerical Input Problem XML: + +=========================== +Numerical Input Problem XML +=========================== + +Templates +--------- + +The following templates represent problems with and without a decimal or percentage tolerance. + +Problem with no tolerance +~~~~~~~~~~~~~~~~~~~~~~~~~ + +.. code-block:: xml + +

TEXT OF PROBLEM + + + +

+ + +
+

TEXT OF SOLUTION

+
+
+ + +Problem with a decimal tolerance +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +.. code-block:: xml + + + +

TEXT OF PROBLEM + + + + +

+ + +
+

TEXT OF SOLUTION

+
+
+
+ +Problem with a percentage tolerance +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +.. code-block:: xml + + + +

TEXT OF PROBLEM + + + + +

+ + +
+

TEXT OF SOLUTION

+
+
+
+ +Answer created with a script +~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +.. code-block:: xml + + + + + + +

TEXT OF PROBLEM + + + + +

+ + +
+

TEXT OF SOLUTION

+
+
+
+ +Tags +---- + +* ```` (required): Specifies that the problem is a numerical input problem. +* ```` (required): Provides a response field where the student enters a response. +* ```` (optional): Specifies a tolerance, or margin of error, for an answer. +* `` + + +
+

Explanation or Solution Header

+

Explanation or solution text

+
+
+ + +Tags +---- + +* ```` +* ```` +* ```` +* `` - - - - - - - -
- -
-
- .. _Text input: @@ -744,7 +578,12 @@ text input problems to allow for typographical errors. Create a Text Input Problem ================================== -To create a text input problem, follow these steps. +You can create multiple choice problems in the Simple Editor or in the Advanced Editor. + +Simple Editor +------------- + +To create a text input problem in the Simple Editor, follow these steps. #. Under **Add New Component**, click **Problem**. #. In the **Select Problem Component Type** screen, click **Text Input** @@ -784,116 +623,11 @@ following. This can fall to such a low probability that malaria is effectively eradicated from the group (even when the group does not have 100% bednet coverage). [explanation] - -========================================= -Multiple Responses in Text Input Problems -========================================= -You can specify more than one correct response for text input problems. -For example, instead of requiring students to enter exactly "Dr. Martin Luther -King, Junior," you can allow answers of "Martin Luther King," "Doctor Martin -Luther King," and other variations. +Advanced Editor +--------------- -To do this, include "or=" (without the quotation marks) before each additional -correct response. - -.. image:: Images/TextInput_MultipleAnswer.gif - :alt: Image of multiple responses in a text input problem - -========================================= -Case Sensitivity and Text Input Problems -========================================= - -By default, text input problems do not require a case sensitive response. You can change this -and require a case sensitive answer. - -To make a text input response case sensitive, you must use :ref:`Advanced Editor`. - -In the advanced editor, you see that the **type** attribute of the **stringresponse** -element equals **ci**, for *case insensitive*. For example: - -:: - - - - - -To make the response case sensitive, change the value of the **type** attribute to **cs**. - -:: - - - - - -============================================= -Response Field Length of Text Input Problems -============================================= - -By default, the response field for text input problems is 20 characters long. - -You should preview the unit to ensure that the length of the response input field -accommodates the correct answer, and provides extra space for possible incorrect answers. - -If the default response field length is not sufficient, you can change it using :ref:`Advanced Editor`. - -In the advanced editor, in the XML block for the answer, you see that the **size** attribute of the **textline** -element equals **20**: - -:: - - - - - -To change the response field length, change the value of the **size** attribute: - -:: - - - - - -==================================================== -Hints and Regular Expressions in Text Input Problems -==================================================== - -You can provide hints for common incorrect answers in text input problems. You can also set a text input problem to allow a regular expression as an answer. To do this, you'll have to modify the problem's XML in the Advanced Editor. For more information, see :ref:`String Response`. - -Although you can create text input problems by using the Simple Editor in Studio, you may want to see or change the problem's underlying XML. For example, you can add hints that appear when students enter common incorrect answers, or modify the problem's XML so that students can submit regular expressions as answers. - -The regular expression that the student enters must contain the part of the answer that the instructor specifies. For example, if an instructor has specified ````, correct answers include ``example answered``, ``two example answers``, or even ``==example answer==``, but not ``examples`` or ``example anser``. - -You can add ``regexp`` to the value of the ``type`` attribute, for example: ``type="ci regexp"`` or ``type="regexp"`` or ``type="regexp cs"``. In this case, any answer or hint will be treated as regular expressions. - -**Sample Problem** - -.. image:: ../Images/TextInputExample.gif - :alt: Image of a string response problem - -**XML Tags** - -.. list-table:: - :widths: 20 80 - - * - ```` - - Indicates that the problem is a text input problem. - * - ```` - - Child of ````. Lists the answer options and contains the ``label`` attribute. - * - ```` (optional) - - Specifies an additional correct answer for the problem. A problem can contain an unlimited number of additional answers. - * - ```` (optional) - - Indicates that the instructor has provided hints for certain common incorrect answers. - * - ```` (optional) - - Child of ````. Specifies the text of the incorrect answer to provide the hint for. Contains answer, type, name. - * - ```` - - Contains the name from ````. Associates the incorrect answer with the hint text for that incorrect answer. - * - ```` - - Indicates the beginning of the text of the hint. - * - ```` - - Indicates the end of the text of the hint. - -**Sample Problem Code** +To create this problem in the Advanced Editor, click the **Advanced** tab in the Problem component editor, and then replace the existing code with the following code. .. code-block:: xml @@ -929,35 +663,113 @@ You can add ``regexp`` to the value of the ``type`` attribute, for example: ``ty -**Template** + + + +========================================= +Multiple Responses in Text Input Problems +========================================= + +You can specify more than one correct response for text input problems. +For example, instead of requiring students to enter exactly "Dr. Martin Luther +King, Junior," you can allow answers of "Martin Luther King," "Doctor Martin +Luther King," and other variations. To do this, you can use the Simple Editor or the Advanced Editor. + +Simple Editor +------------- + +To specify additional correct responses in the Simple Editor, include "or=" (without the quotation marks) before each additional correct response. + +:: + + >>What African-American led the United States civil rights movement during the 1960s?<< + = Dr. Martin Luther King, Jr. + or= Dr. Martin Luther King, Junior + or= Martin Luther King, Jr. + or= Martin Luther King + + + +Advanced Editor +--------------- + +To specify additional correct responses in the Advanced Editor, add an ```` for each correct response inside the opening and closing ```` tags. .. code-block:: xml -

Problem text

- - Correct answer 2 - Correct answer 3 - - - - - Text of hint for incorrect answer A - - - - Text of hint for incorrect answer B - - - - Text of hint for incorrect answer C - - - - -
-

Explanation or Solution Header

-

Explanation or solution text

-
-
-
\ No newline at end of file + +

What African-American led the United States civil rights movement during the 1960s?

+ + + Dr. Martin Luther King, Junior + Martin Luther King, Jr. + Martin Luther King + + + + + + +========================================= +Case Sensitivity and Text Input Problems +========================================= + +By default, text input problems do not require a case sensitive response. You can change this +and require a case sensitive answer. + +To make a text input response case sensitive, you must use :ref:`Advanced Editor`. + +In the Advanced Editor, you see that the **type** attribute of the **stringresponse** +element equals **ci**, for *case insensitive*. For example: + +:: + + + + + +To make the response case sensitive, change the value of the **type** attribute to **cs**. + +:: + + + + + +============================================= +Response Field Length of Text Input Problems +============================================= + +By default, the response field for text input problems is 20 characters long. + +You should preview the unit to ensure that the length of the response input field +accommodates the correct answer, and provides extra space for possible incorrect answers. + +If the default response field length is not sufficient, you can change it using :ref:`Advanced Editor`. + +In the advanced editor, in the XML block for the answer, you see that the **size** attribute of the **textline** element equals **20**: + +:: + + + + + +To change the response field length, change the value of the **size** attribute: + +:: + + + + + +==================================================== +Hints and Regular Expressions in Text Input Problems +==================================================== + +You can provide hints that appear when students enter common incorrect answers in text input problems. You can also set a text input problem to allow a regular expression as an answer. To do this, you'll have to modify the problem's XML in the Advanced Editor. + +The regular expression that the student enters must contain the part of the answer that the instructor specifies. For example, if an instructor has specified ````, correct answers include ``example answered``, ``two example answers``, or even ``==example answer==``, but not ``examples`` or ``example anser``. + +You can add ``regexp`` to the value of the ``type`` attribute, for example: ``type="ci regexp"`` or ``type="regexp"`` or ``type="regexp cs"``. In this case, any answer or hint are treated as regular expressions. \ No newline at end of file diff --git a/docs/en_us/course_authors/source/create_problem_component.rst b/docs/en_us/course_authors/source/create_problem_component.rst index b3f9e05e95..7db06285a9 100644 --- a/docs/en_us/course_authors/source/create_problem_component.rst +++ b/docs/en_us/course_authors/source/create_problem_component.rst @@ -428,10 +428,6 @@ Note that *problem randomization* is different from the **Randomization** settin .. note:: Creating problems with versions that can be randomized requires you to export your course, edit some of your course's XML files in a text editor, and then re-import your course. We recommend that you create a backup copy of your course before you do this. We also recommend that you only edit the files that will contain polls in the text editor if you're very familiar with editing XML. -========================== -Terminology -========================== - =========== Terminology =========== @@ -561,3 +557,34 @@ students to go back and resubmit a problem. - Delete the entire Problem component in Studio and create a new Problem component with the content and settings that you want. Then ask all your students to complete the new problem. + +.. _Problem XML: + +*********** +Problem XML +*********** + +XML tags are generally specific to a problem type. For example, only multiple choice problems contain the ```` tag, and only drag and drop problems use the ```` tag. However, the following tags are common to most problems. + +.. list-table:: + :widths: 20 80 + + * - `` `` + - These must be the first and last tags for any content created in the Advanced + Editor in a Problem component. + * - ```` + - The ```` tag indicates the beginning of a line or block of text. + * - ```` + - The ```` tag indicates the end of a line or block of text. + * - ``
`` (optional) + - If you want to include more information in the problem, such as a detailed explanation of the problem's answer, you'll enter the text between the two ``
`` tags, which are inside the ```` tags. (These tags do not have to be on the same line.) + +Additionally, several different problem types use the following tags. + +.. list-table:: + :widths: 20 80 + + * - ```` + - Creates an answer space where students enter a response. Must contain a **size** attribute; may contain **label**, **math**, **correct_answer**. Used in text input and some custom Python-evaluated input problems. + * - `` `` + -