WeBWork Problem Authoring and Development 1 — Questions and Answers
Question 1: What programming language is WeBWork's PG (Problem Generator) language based on?
- Python
- JavaScript
- Perl (Correct answer)
- Ruby
Correct answer: Perl
PG is built on top of Perl, using Perl syntax and structures to define problem variables, computations, and answer evaluation.
Question 2: What is the primary purpose of using random functions like `random()` in WeBWork PG problems?
- To generate a unique problem ID
- To create different numerical versions of the problem for each student (Correct answer)
- To shuffle the order of answer choices
- To randomly assign problems to homework sets
Correct answer: To create different numerical versions of the problem for each student
Random functions create different numerical values each time a problem is generated, ensuring each student receives a unique version of the problem.
Question 3: Which WeBWork macro library is commonly loaded to enable advanced mathematical object-based answer checking?
- MathFunctions.pl
- PGstandard.pl
- MathObjects.pl (Correct answer)
- AnswerCheck.pl
Correct answer: MathObjects.pl
MathObjects.pl provides a framework for mathematical objects and answer checkers that correctly handle various types like numbers, formulas, and intervals.
Question 4: In PGML (PG Markup Language), how do you render an inline mathematical expression using LaTeX formatting?
- Using [math]...[/math] tags
- Enclosing LaTeX in [` ... `] (backtick brackets) (Correct answer)
- Using $math{...} syntax
- Using \begin{math}...\end{math}
Correct answer: Enclosing LaTeX in [` ... `] (backtick brackets)
In PGML, mathematical expressions are rendered by enclosing LaTeX-formatted math inside [` ... `] backtick brackets.
Question 5: What does the statement `$ans = Real(5)` accomplish in a WeBWork PG problem?
- Assigns the string '5' to a display variable
- Creates a MathObject representing the real number 5 for answer checking (Correct answer)
- Defines a random integer between 1 and 5
- Sets the problem's point value to 5
Correct answer: Creates a MathObject representing the real number 5 for answer checking
Real(5) creates a MathObject of type Real, which supports proper mathematical answer checking including tolerance-based comparisons.
Question 6: What is the Open Problem Library (OPL) in WeBWork?
- A paid subscription service for premium math problems
- A shared repository of community-contributed WeBWork problems organized by subject (Correct answer)
- A library of open-source calculus textbooks integrated with WeBWork
- A database of student performance metrics across institutions
Correct answer: A shared repository of community-contributed WeBWork problems organized by subject
The OPL is a freely available, community-contributed collection of thousands of WeBWork problems organized by subject area and difficulty level.
Question 7: Which WeBWork Problem Editor feature allows instructors to verify a problem's appearance and randomization before assigning it?
- Problem Renderer service
- Live Preview Mode toggle
- Test Student View panel
- The Preview button in the Problem Editor (Correct answer)
Correct answer: The Preview button in the Problem Editor
The Preview button in the WeBWork Problem Editor renders the problem exactly as students will see it, allowing instructors to check formatting and randomized values.
What programming language is WeBWork's PG (Problem Generator) language based on?