my @ints = ( int( rand() * 100 ), int( rand() * 100 ) ); print "Which is larger?\n1) $ints[0]\n2)$ints[1]?\n"; chomp( my $input = <STDIN> ); print "$ints[ $input ] is larger.\n";
In reply to Re: Compare two signed integers without using comparision operator in perl
by chromatic
in thread Compare two signed integers without using comparision operator in perl
by Das
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |