Added support for "%" and "percent" as a unit, acting only as a numerical factor.
Example:
$answer = "5 percent" will accept "5%" or "5 percent"
Not sure if you think there should be any other checks for where "percent" is used. As it sits, since these are now proper units, one may even type "0.05 hectopercent" or even "500 percent^2". Unlikely as those are, they also seem correct(ish), so I don't know how I feel about needing to produce error messages.
Added support for "%" and "percent" as a unit, acting only as a numerical factor.
Example: $answer = "5 percent" will accept "5%" or "5 percent"
Not sure if you think there should be any other checks for where "percent" is used. As it sits, since these are now proper units, one may even type "0.05 hectopercent" or even "500 percent^2". Unlikely as those are, they also seem correct(ish), so I don't know how I feel about needing to produce error messages.