$ perl isnum.t 1..6 ok 1 - $x is a number, &~ ok 2 - $y is a string, &~ Use of strings with code points over 0xFF as arguments to 1's complement (~) operator is not allowed at isnum.t line 12. # Looks like your test exited with 255 just after 2.