Take an example from this past weekend: A “self-check” quiz (not graded, just helps students learn the material) asks that the user convert a series of measurements from one unit to another. It explicitly specifies that the numbers are not to have commas in them. Then, having dutifully entered comma-free answers, the user clicks the button to check their answers, and finds all the questions marked wrong.
Why? The script was checking for answers with commas. And it marks a decimal 0.04 wrong if you attach that first zero (it wants “.04”). Strict grading like this leaves no room for a student’s possible variation upon the convention. So strip out your commas, use parseInt() and parseFloat(), and make sure things work well. Don’t frustrate your students; they already have enough to worry about.