in reply to Unsorted IP Addr list to sorted IP list with ranges

davorg shows an interesting way of sorting IP addresses, using the Guttman-Rosler Transform in his book
my @IP=qw(10.0.4.100 10.0.4.99 10.3.5.21 10.0.4.101 10.15.21.6); my @sorted_IP=map{substr($_,4) } sort map{pack('C4',/(\d+)\.(\d+)\.(\d+)\.(\d+)/).$_}@IP;

TStanley
--------
The only thing necessary for the triumph of evil is for good men to do nothing -- Edmund Burke