The Node List ADT models a sequence of positions storing elements of some arbitrary type. It establishes a before / after relation between positions.
It has generic methods:
size()isEmpty()
We use an argument throughout to indicate the position. Accessor methods:
first()last()prev(p)next(p)Update methods:set(p, e): replace the element at with and return the old eleentremove(p): remove and return the element ataddFirst(e)andaddLast(e)addBefore(p, e)andaddAfter(p, e)