Programming, Java, Lists, Data Structures.
following manner: Given that, there are no elements in the array and we are trying to add an element in the array. The size of the array will be directly increased to 10 and then the new element will be added at index 0. So, basically this condition will be executed. if (this.elementData ==