TrimToSize;
The TrimToSize method sets memory size occupied by the array that is equal to actual number of elements in the array.
The Count property returns the number of array elements. Size of memory allocated to store array elements can be set in the Capacity property. The TrimToSize method is relevant for use if the size of allocated memory is significantly greater that real number of elements in the array.
See also: