0

Hey guys, I was just looking into LinkedList and I came accross couple of methods. I quickly made a linkedlist and added numbers from 0 to 9 in the list then tried different methods such as pop poll, removeFirst and they all returned the same answer from 0 to 9. I am wondering what is the actual difference between those methods?

2
Contributors
2
Replies
6
Views
2 Years
Discussion Span
Last Post by Slavi
0

They are all three the same. Their names come from different ways of looking at and thinking about lists, but in the end they all do the same thing (remove and return the first item in the list).

0

Thank you, James . I guess it comes to preferrences whether to use 1 or other

This question has already been answered. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.