Re: Variable-sized lines of text in linked list
- From: CBFalconer <cbfalconer@xxxxxxxxx>
- Date: Fri, 29 Feb 2008 11:39:35 -0500
Bartc wrote:
.... snip ...
Reading an entire file into memory is an admirable idea, but is
frowned on in this newsgroup for various reasons: the size of a
file is impossible to determine, or could change while you're
reading the file, or because it might be a 100GB monster you
therefore should never attempt this even for tiny files.
That doesn't mean you shouldn't do it; just keep quiet about it
here :-)
Disagree. For some operations, it is virtually necessary. For
example the freverse exercise used as a test for ggets, which
reverses the content of an entire text file, byte by byte.
At the same time bear in mind that many, if not most, general
systems today supply virtual memory. That means that malloc won't
run out of space until the disk does, to all practical purposes.
--
[mail]: Chuck F (cbfalconer at maineline dot net)
[page]: <http://cbfalconer.home.att.net>
Try the download section.
--
Posted via a free Usenet account from http://www.teranews.com
.
- Follow-Ups:
- Re: Variable-sized lines of text in linked list
- From: Ben Pfaff
- Re: Variable-sized lines of text in linked list
- References:
- Variable-sized lines of text in linked list
- From: Scottman
- Re: Variable-sized lines of text in linked list
- From: Bill Reid
- Re: Variable-sized lines of text in linked list
- From: Bartc
- Variable-sized lines of text in linked list
- Prev by Date: Re: Variable-sized lines of text in linked list
- Next by Date: array index and pointer, which is faster?
- Previous by thread: Re: Variable-sized lines of text in linked list
- Next by thread: Re: Variable-sized lines of text in linked list
- Index(es):
Relevant Pages
|