> First, the first argument to split is *always* a regex. A lot of people
> are in the habit of passing a quoted string, but according to the
> perl5-porters (in a thread about a year or so ago) the first argument
> should always be a regex. So, use the // or m// syntax.
>
> Doing that should m
On 03/14/04 17:50, Chris Knipe wrote:
use warnings;
$ARGV[4] = "100.200.30.40"; # for the sake of clarification.
my @IPs = split('.', $ARGV[4]);
First, the first argument to split is *always* a regex. A lot of people
are in the habit of passing a quoted string, but according to the
perl5-porter
use warnings;
$ARGV[4] = "100.200.30.40"; # for the sake of clarification.
my @IPs = split('.', $ARGV[4]);
if ($IPs[1] < 100) {
print "TRUE";
} else {
print "FALSE";
}
running it...
Use of uninitialized value in numeric lt (<) at ./ppp.rotate line 6.
And the condition is *always* true.
Now