"Ryan Moszynski" schreef:

> 1-10;25;33;100-250

echo '1-10;25;33;100-250' | perl -nle '
  /\A\d+(?:-\d+)?(?:;\d+(?:-\d+)?)*\z/ and print "$_ =OK"
'

But that also matches '12-3'.

-- 
Affijn, Ruud

"Gewoon is een tijger."



-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>


Reply via email to