i wonder where the ListNode *tail is
I believe this specific class doesn't have a tail pointer, instead it goes trough items in node list and tries to find an element based on index.
It can work without the tail pointer.
In case you don't often need to add new elements to the end it's not really important.
Usually algorithms just go from one element to the other till the end, so they don't need to know the address of the last one.