http://www.perlmonks.org?node_id=1220634


in reply to Re^4: Match multiple number
in thread Match multiple number

*click!* Got it... For my attempt, adding the \A assertion to match my \z should fix allowing invalid values.

if $n =~ /\A\d{0,}[05]\z/

But, I think I like the [0-9]*[05] based solutions better...

Thanks,