Using both next and continue : Next « Statement « Perl
- Perl
- Statement
- Next
Using both next and continue
while ($loop_index <= 10) {
print "Hello\n";
next if $loop_index > 5;
print "there\n";
} continue {
$loop_index++;
}
Related examples in the same category