difference between arraylist and linkedlist otherthan
performance
Answers were Sorted based on User's Feedback
Answer / db
In array list if we perform insertion or deletion operation, then there is many changes in the remaining objects to get adjust. if any operation like insertion or deletion is performed on linked lists there is only updation links between the nodes. so if there is lots of insertions and deletions better to go with linked lists rather than array list.
Is This Answer Correct ? | 10 Yes | 3 No |
Answer / rahul
There are lot of method in LinkedList like addFirst(),
addLat(), pop(), peak() etc.
But ArrayList dont.
Is This Answer Correct ? | 3 Yes | 2 No |
Can we start a thread twice in java?
What value is a variable of the string type automatically initialized?
Is hashmap thread safe?
can u handle an error if u write Thowable in the catch class lise try { some errorneous code }catch(Throwable e){ ...}
What is the difference between the >> and >>> operators?
Explain the importance of finalize() method.
Lowest Common ancestor in a Binary Search Tree and Binary Tree.
What are "methods" and "fields"?
Variable of the boolean type is automatically initialized as?
What is “try and catch” in java
These static constructors are correct ? class A { statc intA() { } static A(int x,int y) { } static A(int x) { } }
What happens when main () method is declared as private?