|
-
February 14th, 2010, 11:12 AM
#1
[RESOLVED] Vector reserving memory, vs linked list
Hey all,
due to the generic nature of what I am searching for I am finding it difficult to google my question so sorry if it seems obvious.
When a vector is initialised it creates a space in memory, if reserve is used it will reserve enough for X elements.
Does this mean then, that somewhere in memory you will need a chunk of X*NumBytes of unused space to allocate?
What I am trying to get at is, if you were working on a system with limited memory would it be better to use a linked list because you can allocate memory all over the place and point to it as opposed to needing a chunk in one place?
That is my perception so far, please do correct me if that is wrong.
Tags for this Thread
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|