Im working on a Java question and need guidance to help me study.
1. Write a recursive method find in LinkedList class. The method should return true if the given value is in the list whose front is the parameter front, false otherwise. The recursive method should have the following header:
private boolean find(Node front, E value)
You should also provide a public method clients (and your main) can call that will call the private recursive method
public boolean find(E value)
2. Overload toString with the recursive method
String toString(Node front)
which returns a string representation of the linked list starting at the node sent in as a parameter. Then modify the existing toString method, the one that overrides Objects toString, so that it calls your recursive method instead of looping.
The post add 3 methods of this lab appeared first on learnedprofessors.