Scripting
>>
Perl
>>
How to read one line at a time from a text file
1. while (
) { 2. no actual read command needed, a newline will be read into $_ till eof encountered. 3. If need to remove the "\n" character at the end, use chop.
Please enable JavaScript to view the
comments powered by Disqus.