if ($text =~ /^\d+$/) {print "It's a number.";}
$text = "345"; if ($text =~ /^\d+$/) {print "It's a number.";}