in reply to sorting arrays with common index

You really should learn about arrays of hashes from perldsc, but here you go:
my @order = sort { $HOST_NAME[$a] cmp $HOST_NAME[$b] } 0 .. $#HOST_NAM +E; foreach my $i (@order) { print "$HOST_IP[$i]:$HOST_NAME[$i]:$HOST_DESCRIPTION[$i]\n"; }