in reply to RE: RE (tilly) 2: Adding 2 + 2
in thread Adding 2 + 2
Is that integer range "between 1 and 3" inclusive or exclusive?
You might want to include some error-checking:
{ print "Pick an integer between 1 and 3 (exclusive):" $mynum1 = <STDIN>; (print "Follow instructions!\n"),redo unless ($mynum < 3) and ($mynum > 1) and ($mynum == int($mynum)); }
In Section
Cool Uses for Perl