I am trying to have feedback appear for students after submitting their answer in a math input.
Currently, I am using a Sketch, Note, and Math Input with this code in the Math Input. When I try the feature, I am not seeing my feedback.
chk2=when Bisects.numericValue=20 “Yes! That is right!” otherwise "
(Not sure if you’re missing the final quotes). chk2 is a variable that holds text that just lives in your Math Input CL. If you want the feedback to be in your note, it would be better to put that code in the Note CL. Then, use the {#} button in the main editing screen to insert it.
Or if your content is defined in the CL, you need to reference your variable like this:
chk2=when Bisects.numericValue=20 "Yes! That is right!" otherwise ""
content: "Your text here.
${chk2}"
(Also, if you see the curved quotation marks, you need to change them to the vertical ones.) This “Yes! That is right!” versus this "Yes! That is right!"
If you want feedback on incorrect answers, you might consider making that appear only when the submit button is pressed, otherwise the feedback will appear immediately on any keyboard press and the student could get confused or end up doing lots of guess and check. Here’s what that would look like.
chk2= when Bisects.numericValue=20 "Yes! That is right!"
when Bisects.submitted and not(Bisects.numericValue=20) "That's not correct."
otherwise ""