my $i; for $i (1..10) { last if &condition($i); } &do_more_stuff_with_the_value_found($i); #### my $i; for ($i=1; $i<=10; $i) { last if &condition($i); } &do_more_stuff_with_the_value_found($i);