Re: Question about perlreref - are {n} and {n}? different?
- From: Juha Laiho <Juha.Laiho@xxxxxx>
- Date: Sat, 29 Oct 2005 05:21:37 +0000 (UTC)
"Dr.Ruud" <rvtol+news@xxxxxxxxxxxx> said:
>usenet@xxxxxxxxxxxxxxx schreef:
>> perlreref::QUANTIFIERS says:
>>
>> Quantifiers are greedy by default -- match the longest leftmost.
>> Maximal Minimal Allowed range
>> ------- ------- -------------
>> {n,m} {n,m}? Must occur at least n times but no more than m times
>
>
>The 'Must occur ... no more than m times' is not accurate.
Hmm.. given a little bit more context, it is accurate:
AX{n,m}B
Here, to make the whole RE match, you must have an A, followed by at least
n, but no more than m Xs, followed by a B.
--
Wolf a.k.a. Juha Laiho Espoo, Finland
(GC 3.0) GIT d- s+: a C++ ULSH++++$ P++@ L+++ E- W+$@ N++ !K w !O !M V
PS(+) PE Y+ PGP(+) t- 5 !X R !tv b+ !DI D G e+ h---- r+++ y++++
"...cancel my subscription to the resurrection!" (Jim Morrison)
.
- Follow-Ups:
- References:
- Question about perlreref - are {n} and {n}? different?
- From: usenet
- Re: Question about perlreref - are {n} and {n}? different?
- From: Dr.Ruud
- Question about perlreref - are {n} and {n}? different?
- Prev by Date: FAQ 8.20 How can I call my system's unique C functions from Perl?
- Next by Date: Re: Typing tutor help script needed, please
- Previous by thread: Re: Question about perlreref - are {n} and {n}? different?
- Next by thread: Re: Question about perlreref - are {n} and {n}? different?
- Index(es):
Relevant Pages
|