1.

How To Add Elements To An Arraylist?

Answer»
  • List provides a method ADD(E e) which appends specified element to the end of the list. USING add(E e) method will MEAN keep adding elements SEQUENTIALLY to the list.
  • Another add method - add(int INDEX, E element) inserts the specified element at the specified position in this list.
  • Third method addAll(int index, Collection<? extends E> c) inserts all of the elements in the specified collection into this list, starting at the specified position.



Discussion

No Comment Found