Difference between array and Arraylist..
ARRAY
|
ARRAYLIST
| |
1.
|
Char[] vowel=new Char[];
|
ArrayList a_list=new ArrayList();
|
2.
|
Array is in the System namespace
|
ArrayList is in the System.Collections namespace.
|
3.
|
The capacity of an Array is fixed
|
ArrayList can increase and decrease size dynamically
|
4.
|
An Array is a collection of similar items
|
ArrayList can hold item of different types
|
5.
|
An Array can have multiple dimensions
|
ArrayList always has exactly one dimension
|
No comments:
Post a Comment