Regex issue - asterisk after \d
I'm using http://gskinner.com/RegExr/ to test my regex:
[+-]?\d+\.?\d*(e[+-]?\d+)?. It's supposed to match floating point numbers.
Currently it doesn't match .x, but I want to make it do that.
I tried changing it to [+-]?\d*\.?\d*(e[+-]?\d+)? (changed + to *) but
that's an error. What's going wrong here?
Update: is it because everything is optional?
No comments:
Post a Comment