Help for this page
use IO::Socket::INET; ... print "Port $port ", $sock ? "OPEN\n" : "CLOSED\n"; $sock->close if $sock; }