my $x=111; my $y="111"; print "\$x is a number\n" if !($x & ~$x); print "\$y is a string\n" if ($y & ~$y);