in reply to next within one subroutine that looks to another subroutine
sub action { for my $i (@list) { my $rc = decide($i); next unless $rc; # Do stuff here with $rc } } sub decide { my $i = shift; return 0 if $i =~ /^C/; print $i, $/; }
------
We are the carpenters and bricklayers of the Information Age.
Don't go borrowing trouble. For programmers, this means Worry only about what you need to implement.
|
|---|