Linked-List Implementation
e.g. IntList - list of integers
- List is a set of records called cells.
- Each cell references the next cell in the list.
- The list itself is identified with reference to the first cell.
- The empty list is the null reference.
The record for an IntList cell thus consists of two values:
int: the integer stored in the cell
IntList: the reference to the next cell
Link to IntList.java.
Next Slide | Previous Slide | Contents |