AlejandroLoutphi / MetroMendeleyLoutphiRuizZaherAlDeen

0 stars 0 forks source link

Port LinkedList<E> #5

Closed AlejandroLoutphi closed 3 months ago

AlejandroLoutphi commented 3 months ago

New methods to be added:

AlejandroLoutphi commented 3 months ago

To iterate over the list with a for loop, do

for (LinkedListNode<E> i = theListToIterateOver; i != null; i = i.getNext()) {
    thing = i.getElt();
    //do stuff with thing
}

Replace E with whatever type the list has

AlejandroLoutphi commented 3 months ago

Done, see results in 2-box