Perl

TAMTOWTDI

The followings are equivalent. if ($x == 0) {$y = 10;} else {$y = 20;} $y = $x==0 ? 10 : 20; $y = 20; $y = 10 […]…Read more

gethostbyaddr

my $host = $ENV{'REMOTE_ADDR'}; my $name = gethostbyaddr(pack('C4',split(/?./, $host)),2); $na […]…Read more