programming-examples/perl/Statement/Last with label.pl
2019-11-15 12:59:38 +01:00

16 lines
230 B
Perl

#!/usr/bin/perl -w
use strict;
my $i = 1;
OUTER: while ($i <= 5) {
my $j = 1;
while ($j <= 5) {
last OUTER if $j == 3;
print "$i ** $j = ", $i ** $j, "\n";
$j++;
}
$i++;
}