4 ms·
Nitpicking > "This might be as simple as printing the number with your locale's version of numerical separators, like "123,456" or "123.456" or "123 456" or wh
by aqme28 6y ago
Nitpicking
> "This might be as simple as printing the number with your locale's version of numerical separators, like "123,456" or "123.456" or "123 456" or whatever else you might use where you are. The trick is then to NOT accept that as input, but instead demand that they remove the separator and jam it in as just digits. "
It's easier to just strip non-digit characters than to parse the input for them and respond accordingly. This is a confirmation step with basically a checksum, so you're not going to get many false positives.