while () { next unless 3..7; # ignore all lines except between 3 and 7 included print; } __DATA__ One Two Three Four Five Six Seven Eight Nine