How to check when simplifying expressions

Hello!

I want my students to input expressions that are simplified (using GCF for example), and then be able to check it themselves.

I can see what to insert in the code to check if the answer is an equation, or a number, but how do I do this for an expression?

For example, the q I give them is to simplify 48x-16…the answer I want them to write is 16(3x-1), and then check to see if they are correct.

TIA!!!

You can use simpleFunction() to turn an expression into a function, then evaluate as you would an equation. Is that what you mean? If you want to see that it’s simplified, you’ll want to find some threads that discuss countNumberUsage.

Here’s one: