my $totalArray = system ( "nslookup", "$nodeName"); my @totalArraySplit = split(":", $totalArray); print STDOUT ("$totalArraySplit[1]\n");