I'm trying to read 2 files each has aprox 1MB but when I check for memory usage i get 2MB
(this still persist for more file f*1mb)
It is possible to read each file with minimum memory usage?
Jump to Post
It all depends on how you read the files. In general, with buffered reading, like with
ifstream, the stream will read blocks of data ahead of what you are currently reading. The reason for this is to minimize the time usage, because it's more efficient to read substantial blocks of …
All 2 Replies
Be a part of the DaniWeb community
We're a friendly, industry-focused community of 1.21 million developers, IT pros, digital marketers, and technology enthusiasts learning and sharing knowledge.