SPUG:m,n -- why?

Creede Lambard creede at penguinsinthenight.com
Sat Mar 15 09:24:34 CST 2003


On Fri, 2003-03-14 at 23:24, Michael R. Wolf wrote:
> Does anyone know the historical roots of "n" and "m" for "min" and
> "max" in the regex quantifiers?  I can never get a mnemonic for which
> is which.  (Of course, the min is to the left of the max.)  Perhaps if
> I know it's roots, I'll remember.
> 
> That is (n,m) = (0,7) in this snippet:
> 
>     if ($fruit =~ /b(an){0,7}a/) {
>         print "You've got an modular banana\n";
>     }

Well, there is an "n" in "minimum" but not in "maximum." That's my
guess.

-- 
Creede Lambard <creede at penguinsinthenight.com>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part
Url : http://mail.pm.org/pipermail/spug-list/attachments/20030315/053368a5/attachment.bin


More information about the spug-list mailing list