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.