February 2012
Intermediate to advanced
1184 pages
37h 17m
English
do BLOCKThe do
BLOCK form executes the sequence of statements in the
BLOCK and returns the value of the last
expression evaluated in the block. When modified by a while or until statement modifier, Perl executes the
BLOCK once before testing the loop condition.
(On other statements, the loop modifiers test the conditional first.)
The do
BLOCK itself does not
count as a loop, so the loop control statements next, last,
or redo cannot be used to leave or
restart the block. See the section Bare Blocks as Loops in
Chapter 4 for workarounds.
Read now
Unlock full access