ArrayList has some neat methods, such as add(), remove(), and contains().
An array String[]
cannot expand its size. You can initialize it once giving it a permanent size:
String[] myStringArray = new String[10]();
myStringArray[0] = "Test";
An ArrayList
is variable in size. You can add and remove items dynamically:
ArrayList myStringArrayList = new ArrayList();
myStringArrayList.add("Test");
myStringArrayList.remove(
1);
Furthermore, we can sort, clear, addall, and a lot more functions and can use while using an ArrayList.