good chemistry is complicated, and a little bit messy -LW |
|
PerlMonks |
Re: Pinggerby Trinary (Pilgrim) |
on Apr 26, 2001 at 01:42 UTC ( [id://75630]=note: print w/replies, xml ) | Need Help?? |
When you construct the @iparray, you put a newline after each IP. Then when you use the @iparray to print out $host is alive, the newline is in the middle of whatever line it is you're printing. Additionally, you have no newline at the end of the print " $host is alive "; line, thus garbling your output a bit. Take the \n out of your map, and put one in your print to get one correctly formatted result on each line.
In Section
Seekers of Perl Wisdom
|
|