vinoth.ree has asked for the wisdom of the Perl Monks concerning the following question:
while (<>) { print "$. $_" if 3 .. 10; }
The above code prints lines 3 to 10 of any input or file given to it. If we change it to "print "$. $_" if 3 ... 10;" it works the same way. How ?
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Range operators .. and ...
by lakshmananindia (Chaplain) on Apr 10, 2009 at 04:24 UTC |