I have an ArrayList l1 of size 10. I assign l1 to new list reference type l2. Will l1 and l2 po
ArrayList
l1
l2
There is a method addAll() which will serve the purpose of copying One ArrayList to another.
For example you have two Array Lists: sourceList and targetList, use below code.
targetList.addAll(sourceList);