|
|
Hi,
It's probably a stupid question, but here goes. I know that for every
"new", there must be a delete. I don't deal with malloc statements, so
let's disregard that branch of memory management.
So here's the question. If I create an array like so: int i[20];, and
then proceed to assign values for each entry, must I then delete it at
some point? I didn't use a "new" flag to initialize the array. Is the
memory used by that array freed after the program is terminated?
I can't find information regarding this, as all the texts I found dealt
with the "new" and "delete []" statements.
I ask this because my Light's Out game seem to use more and more memory
each time it is run and closed, but the memory consumption actually goes
back down to what it originally was after the 11th or 12th time. I don't
get why that would happen...
Sam
Post a reply to this message
|
|