Checking if Math Input Answer is correct when comparing to a variable's value

I’m creating slides that have equations with randomly generated values as coefficients. Is there a way to check the students’ math input answers using something like

correct: (this.numericValue = “g”)

where g is what the answer would be given each random equation generated?


Sure. Something like this?

Thank you so much. That worked.