Beefy Boxes and Bandwidth Generously Provided by pair Networks
"be consistent"
 
PerlMonks  

Re: (Golf) Expression for matching numeric IP addresses

by hv (Prior)
on Aug 10, 2004 at 13:32 UTC ( [id://381576] : note . print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
      (eval$_)=~/^[\0-\xff]{4}\z/
    
  2. or download this
      (eval"0.0.$_")=~/^\0\0(.|[\0-\xff]([\0-\x{ffffff}]|[\0-\xff]([\0-\x{
    +ffff}]|[\0-\xff]{2})))\z/s