get(index);
/*
Return element at given index.
If passed arg "index" is invalid, throws exception:
"(get) Index %d is out of bounds"
*/
given "index" (the pos to access) count = 0 node = firstNode While node is not null If (count equals index) Return the node's data node = node.getNextNode() Increment count
first(); /* Return first element If list is empty, throws exception: "(first) Attempted to access element in empty list" */ last(); /* Return last element If list is empty, throws exception: "(last) Attempted to access element in empty list" */