Imports System
Imports System.Collections.Generic
Public Class Example
Public Shared Sub Main()
Dim numbers As New List(Of String)
Console.WriteLine("Capacity: {0}", numbers.Capacity)
numbers.Add("One")
numbers.Add("Two")
numbers.Add("Three")
numbers.Add("Four")
numbers.Add("Five")
numbers.TrimExcess()
Console.WriteLine("Capacity: {0}", numbers.Capacity)
Console.WriteLine("Count: {0}", numbers.Count)
End Sub
End Class