linked list can now return index of argument