[Tutor] Suggestions as to how to read a file in paragraphs

Bill Campbell bill at celestial.net
Wed Sep 1 23:00:37 CEST 2004


On Wed, Sep 01, 2004, Alan Gauld wrote:
>> What is a more efficient way to read a file and split it into
>paragraphs
>> and just print those paragraphs which match a particular condition?
>
>First, do you need the efficiency? Is it actually causing a problem
>just now?

This sounds like somebody who is accustomed to perl's ability to tweak a
variable causing the read operation to suck in paragraph at a time.  Every
time I've wanted to use this in perl, I've had to either go back to the
perlvars documentation or find an existing program that used it to figure
out what the variable name is.

Bill
--
INTERNET:   bill at Celestial.COM  Bill Campbell; Celestial Software LLC
UUCP:               camco!bill  PO Box 820; 6641 E. Mercer Way
FAX:            (206) 232-9186  Mercer Island, WA 98040-0820; (206) 236-1676
URL: http://www.celestial.com/

Many companies that have made themselves dependent on [the equipment of a
certain major manufacturer] (and in doing so have sold their soul to the
devil) will collapse under the sheer weight of the unmastered complexity of
their data processing systems.
		-- Edsger W. Dijkstra, SIGPLAN Notices, Volume 17, Number 5


More information about the Tutor mailing list