What is the difference between
ArrayList<Object> al = new ArrayList<Object>(100);
and
Object[] ar = new Object[100];
Is there any difference in the internal implementation i.e. the allocation in the memory? Do both internally reserve 100 slots in the memory?
See Question&Answers more detail:os