Closed vaibhav26sharma closed 3 years ago
The method remove() in CLL https://github.com/ani03sha/Algorithms/blob/develop/src/main/java/org/redquark/algorithms/datastructures/lists/CircularLinkedList.java#L112 , doesn't handle the edge case where the element to be removed is the tail itself.
In that case there needs to be an additional check and the tail reference needs to be updated to the last second element.
The method remove() in CLL https://github.com/ani03sha/Algorithms/blob/develop/src/main/java/org/redquark/algorithms/datastructures/lists/CircularLinkedList.java#L112 , doesn't handle the edge case where the element to be removed is the tail itself.
In that case there needs to be an additional check and the tail reference needs to be updated to the last second element.