-- Final Review Question#2
Originally Posted By: dburke
Also, if this question is on the exam, I would think you'd want to say a fair bit more on the what free space list is and what it is used for. Some important points could include:
- singly linked list
- intertwined with the linked list of actively in use nodes/objects
- the head of the list is maintained by a variable, When a new node/object is needed, it is taken from the head of the free list and then the free list head variable is adjusted to point to the next node/object in the free list.
- object "deleted" from active in use linked list are simply returned to free list: the objects next pointer is updated and the free list head variable is updated.
- in this way, a free list works like a stack
-
'''Originally Posted By: dburke'''
Also, if this question is on the exam, I would think you'd want to say a fair bit more on the what free space list is and what it is used for. Some important points could include: <br> - singly linked list<br> - intertwined with the linked list of actively in use nodes/objects<br> - the head of the list is maintained by a variable, When a new node/object is needed, it is taken from the head of the free list and then the free list head variable is adjusted to point to the next node/object in the free list.<br> - object "deleted" from active in use linked list are simply returned to free list: the objects next pointer is updated and the free list head variable is updated.<br> - in this way, a free list works like a stack<br><br> -