Closed christianp closed 1 year ago
Hi, I would like to try.
@hafhaf10 thanks for offering to help! Please look at our guide on contributing code to Numbas. The marking functions are defined in runtime/scripts/marking.js
- you should add a new function 'add_credit_if'
.
Hi, i would also like to try to contribute to this issue.
This is a common pattern: I have a list of independent criteria that a student's answer must fulfil. For each of them, I want to add a certain amount of credit if it's satisfied, and give some negative feedback otherwise.
At the moment, it's possible with this:
It would be convenient to have a function
add_credit_if(condition, amount, positive_feedback, negative_feedback)
which is equivalent to the above code.