|
|
On Wed, 03 Oct 2007 00:36:05 +0200, Samuel Benge
<stb### [at] THIShotmailcom> wrote:
> 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?
No. Indeed, you must not, as it is not dynamically allocated.
> Is the memory used by that array freed after the program is terminated?
It is freed when 'i' goes out of scope. If 'i' is in namespace scope, it
goes out of scope when the program ends.
--
FE
Post a reply to this message
|
|