return first==null/true if list is empty /public listiterator getiterator(/return iterator return new listiterator(this)/initialized with /this list /public void displaylist(link current first/start at beginning of list while(current !null/until end of listcurrent displaylink()/print data current current next/move to next link system out println("")//end class linklist ///////////////////////////////////////////////////////////////class listiterator private link currentprivate link previousprivate linklist ourlist/current link /previous link /our linked list //public listiterator(linklist list/constructor ourlist listreset()//public void reset(/start at 'firstcurrent ourlist getfirst()previous null//public boolean atend(/true if last link