Beefy Boxes and Bandwidth Generously Provided by pair Networks
There's more than one way to do things
 
PerlMonks  

Re^2: sorting ip octets

by Anonymous Monk
on Feb 16, 2005 at 19:04 UTC ( #431683=note: print w/replies, xml ) Need Help??


in reply to Re: sorting ip octets
in thread sorting ip octets

thanks it works but I open it from a txt file and read it line by line.

thank you for the help

Replies are listed 'Best First'.
Re^3: sorting ip octets
by Tanktalus (Canon) on Feb 16, 2005 at 19:08 UTC

    Normally, we recommend reading files and dealing with them line-by-line. That doesn't really work for sorting. So just read your text file into @ips, chomping as appropriate, and then sort as above. All I was helping you with was the sorting of ip octets, not the reading of a file or writing to a file. Those are left as an excersise for the reader. (I never knew how much fun it was to say that until I left university... :-})

      I appreciate all the help you have given me.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://431683]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others musing on the Monastery: (4)
As of 2022-08-18 18:58 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?