3946 shaares
2034 private links
2034 private links
Whatever your programs are doing, they often have to deal with vast amounts of
data. This data is usually represented and manipulated in the form of strings.
However, handling such a large quantity of input in strings can be very
ineffective once you start manipulating them by copying, slicing, and modifying.
Why?
Let's consider a small program which reads a large file of binary data, and
copies it partially into another file. To examine out the memory usage of this
program, we will use memory_