while( ) { chomp; if( is_empty($_) ) { print "$.: ---\n" if is_empty($_); } else { print "$.: $_\n"; } goto JUMP if $. == 4; } sub is_empty { return ! length $_[0]; } BEGIN { print "Beginning execution.\n" } JUMP: { print "Look, found the JUMP block.\n"; } __DATA__ First line Third line Fourth line Fifth line