ZTliYWRjMmM4NzFjMzNlN2IzMjgyZjIwODllNzE5ZWI1OTc5MWQ0NGQ5MDlhZWZhYWVjMmEyYzQ3MGIzYzQ1Yg.msfhd53s.eyJ1cmwiOiIvcGwvY291cnNlX2luc3RhbmNlLzIvaW5zdGFuY2VfcXVlc3Rpb24vMTg3LyIsImF1dGhuX3VzZXJfaWQiOiIxIn0
Skip to main content Accessibility guide
PrairieLearn Go home
  • XC 101, SectionA
  • Assessments
  • Gradebook
  • C4
Load from disk
  • Dev User student
    View type
    ✓ Staff view staff ✓ Student view student ✓ Student view without access restrictions student
    Effective user
    Customize…
    Course Requests Settings Log out

Regenerate assessment instance

Warning: Regenerating the assessment instance will select a new set of questions from this assessment. Any progress on the current assessment instance will be lost.

Are you sure you want to regenerate the assessment instance?

Course staff: Regenerate your assessment instance to pick up changes to the assessment or to get a fresh set of questions.

C4.17. Element pl-matching: Match statements with options

This question illustrates different use cases for the pl-matching element.

Example 1: Match each nation with its capital city. In this example, the options are implicitly created by each statement's match attribute. Only distractor options need to be added manually. All statements and options are displayed by default.

United States
France
Canada
Mexico
  1. Paris
  2. Toronto
  3. Mexico City
  4. Tijuana
  5. New York City
  6. Ottawa
  7. Washington, D.C.

Example 2: Setting counter-type="full-text" will hide the column of options. The dropdown list next to each statement will contain the inner text of each option, rather than a counter.

headshot of Matt
headshot of Mariana

Example 3: blank="false" removes the blank first entry in the dropdown list, setting the default selection to the first option.

France
United States
Canada
Mexico
  1. New York City
  2. Mexico City
  3. Tijuana
  4. Toronto
  5. Ottawa
  6. Paris
  7. Washington, D.C.

Example 4: number-statements and number-options determine how many statements and options are shown. Statements are sampled at random. The options will always include each correct match for the sampled statements, plus random distractors.

Mexico
France
United States
  1. Washington, D.C.
  2. Paris
  3. Tijuana
  4. New York City
  5. Mexico City

Example 5: if number-options is smaller than the amount of options required to match the sampled statements, None of the Above will be added.

Mexico
Canada
France
  1. Mexico City
  2. Paris
  3. None of the above

Example 6: the counter-type attribute indicates how options are identified. It can be set to lower-alpha (a, b, c, ...), upper-alpha (A, B, C, ...), or decimal (1, 2, 3).

Canada
United States
Mexico
  1. Ottawa
  2. Mexico City
  3. Washington, D.C.

Example 7: options can be added manually if they require more than simple text (e.g., images, equations or formatting). In that case, the name attribute of each pl-option must match the corresponding match attribute of the appropriate pl-statement.

$i$
$\phi$
$e$
  1. $\cfrac{1+\sqrt{5}}{2}$
  2. $\sqrt{-1}$
  3. $ \displaystyle \lim_{n \to \infty} \left(1 + \frac{1}{n}\right)^{n}$

Example 8: HTML formatting and other PrairieLearn elements can be used inside statements and options. If used in options, an explicit pl-option must be defined with a name attribute matching the corresponding match attribute of the appropriate pl-statement.

1
list(map(lambda item: item * 2, lst))
1
list(filter(lambda item: item > 0, lst))
1
list(itertools.product(lst1, lst2))
  1. 1
    [item for item in lst if item > 0]
    
  2. 1
    [(a, b) for a in lst1 for b in lst2]
    
  3. 1
    [item * 2 for item in lst]
    

Example 9: This example uses the options-placement="bottom" argument. This is useful for questions with long statements and options, which may wrap over multiple lines or cause formatting issues in the default "right" placement.

What biotechnology technique offers potential in treating genetic disorders and enhancing crop yields?
What field of computer science encompasses machine learning, natural language processing, and computer vision?
Which theory revolutionized our understanding of space, time, and gravity?
What is a branch of physics that challenges classical intuition and underpins technologies like quantum computing?
  1. The theory of relativity
  2. Traditional computing
  3. Quantum mechanics
  4. Artificial intelligence
  5. Data science
  6. Genetic engineering
  7. OPERA faster-than-light neutrino anomaly
  8. String theory
Additional attempts available with new variants

Correct answer

Collection 4

Assessment overview
Total points: 0/360
Score:
0%

Question C4.17

Value: 2
All variants: Open (current)
Total points: — /10
Auto-graded question

This form is only for reporting errors in the question itself. Do not use this form if you just don't know how to answer the question.

Previous question Next question

 Personal Notes

No attached notes

Attached files will be saved here for your reference. These files act as personal notes and can be used for your own review purposes. They are not used for grading.

Max file size: 10 MB

Attached personal notes will be saved here for your reference. These notes can be used for your own review purposes. They are not used for grading.

Staff information

Student details

Dev User
dev@example.com

Question

QID:
element/matching
Title:
Element pl-matching: Match statements with options

Variant

Started at:
2026-08-04 16:37:57 (CDT)
Duration:
0s
Show/Hide answer
{
  "ex1": [
    6,
    0,
    5,
    2
  ],
  "ex2": [
    1,
    0
  ],
  "ex3": [
    5,
    6,
    4,
    1
  ],
  "ex4": [
    4,
    1,
    0
  ],
  "ex5": [
    0,
    2,
    1
  ],
  "ex6": [
    0,
    2,
    1
  ],
  "ex7": [
    1,
    0,
    2
  ],
  "ex8": [
    2,
    0,
    1
  ],
  "ex9": [
    5,
    3,
    0,
    2
  ]
}

Assessment instance

Assessment:
gallery/elements
Started at:
2026-08-04 16:37:17 (CDT)
Duration:
0s
View log
This box is not visible to students.