in reply to Should be a simple spaces/digits regex....but I'm turning grey!
# n-1 spaces or digits: vv vvvvv: last digit (?:(?=\s[\s0-9]|[0-9]{2})[\s0-9]){15}[0-9] # (^^^^^^^^^^^^^^^^) ^^^^^^^: leading chars
and only allow \s\s, \s\d, or \d\d at each point along the way.
Note that I always use [0-9] and never \d as, these days, \d includes tons of characters besides '0'..'9'.
- tye
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Should be a simple spaces/digits regex....but I'm turning grey! (?=)
by Bethany (Scribe) on Aug 05, 2014 at 02:16 UTC | |
|
Re^2: Should be a simple spaces/digits regex....but I'm turning grey! (?=)
by Anonymous Monk on Aug 05, 2014 at 02:25 UTC | |
by tye (Sage) on Aug 05, 2014 at 02:36 UTC |