Quest Ladder
TeachFORGE.ai
Quest Ladder / Code execution
Code execution questions
Set the language, write the test cases, and let the code be judged by whether it works.
Code either runs or it does not. That is a rare gift in marking.
What it is
The learner writes code; the code is run against test cases; the result decides the mark. Two settings shape it in Extra settings: Language, and Test cases from 1 to 6 with a default of 2.
It is the only format where a wrong answer can be wrong in a way that is genuinely informative without you writing anything — the failure itself tells the learner which case they did not handle.
Writing the test cases
Two cases is the default and the minimum useful number: one that any plausible attempt passes, and one that separates a real solution from a guess. Six is the ceiling, and the ceiling is there for a reason — a learner who fails five of six learns less than one who fails the single case that matters.
- Make the first case the obvious one, so a learner on the right track gets feedback that they are.
- Make one case the edge: empty input, zero, a negative, the boundary of a range.
- Avoid cases that only differ by size. A test that is the same shape with bigger numbers is checking patience.
Ignore whitespace when comparing output on the correct answer step is almost always the right setting. Without it, a trailing newline fails a correct program, and the learner has no way to see why.
Marks and partial credit
Each test case is a slot with its own marks, so Marking mode set to Weighted gives credit for the cases that pass. A learner whose solution handles the normal path but not the empty input has written something worth most of the marks.
All-or-nothing has a place — when the question is explicitly make all the tests pass — but as a default it throws away the most useful signal the format produces.
What it does not do
Test cases check behaviour, not quality. Code that passes every test can still be unreadable, quadratic where it should be linear, or a hard-coded table of the expected answers.
If style or efficiency is part of what you are teaching, pair this with a written question that asks the learner to explain their approach, and mark that in the marking queue. The tests handle correctness; you handle the rest.