Page 1 of 1

non-existant regexp function

PostPosted: Sun Sep 07, 2003 9:31 pm
by Takamatsu
I noted this regexp function doesn't exist in newsbin.

In my early experience with regexp, I have encountered an application which uses the following syntax.

{1,10}

Which means... "at least 1 of the previous character, and at most 10."

For example.
[0-9]{1,5} will match numeric strings ranging from 0 to 99999.

I take it that this is a non-standard syntax, but it is obviously very powerful and useful.

PostPosted: Mon Sep 08, 2003 2:58 am
by Smite
For now, you can write it out longhand:
[0-9]{1,5} = [0-9][0-9]?[0-9]?[0-9]?[0-9]?