1. [OVERFLOW?] If AVAIL = NULL, then: Write: OVERFLOW, and Exit.
2. [Remove first node from AVAIL list.]
3. Set INFO[NEW] : = ITEM. [Copies new data into new node.]
4. If LOC = NULL, then: [Insert as first node.]
Set LINK[NEW] : = START and START : = NEW.
Else: [Insert after node with location LOC.]
Set LINK[NEW] : = LINK[LOC] and LINK[LOC] : = NEW.
[End of If structure]
5.Exit.
0 comments:
Post a Comment