Honestly, that is *exactly* how I do it! :-)if ($number =~ /\D/) { print "$number is not an integer\n"; } elsif ($number =~ /[02468]$/) { print "$number is even\n"; else { print "$number is odd\n"; }
In reply to RE (tilly) 3: The Big Test
by tilly
in thread The Big Test
by japhy
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |