C
Christie Taylor
I'm new to regular expressions and am trying to create a fairly simple
one to validate input. The goal is to accept an optional word followed
by zero or one spaces, then a required number of 1 to 8 digits.
I tried m/^word\s{0,1}\d{1,7}/i to get started (ignoring my optional
part) but this is not working, it's matching on way too much. What am I
missing?
Thanks!
one to validate input. The goal is to accept an optional word followed
by zero or one spaces, then a required number of 1 to 8 digits.
I tried m/^word\s{0,1}\d{1,7}/i to get started (ignoring my optional
part) but this is not working, it's matching on way too much. What am I
missing?
Thanks!