Next statement with if statement : Next « Statement « Perl
- Perl
- Statement
- Next
Next statement with if statement
@a = (0 .. 20);
@b = (-10 .. 10);
DIVISION: while (@a) {
$a = pop @a;
$b = pop @b;
next DIVISION if ($b == 0);
print "$a / $b = " . $a / $b . "\n";
}
Related examples in the same category