Calling `Clear()` on a list initialized with an initial capacity

Viewed 1032

I have a list with a specified initial capacity:

private void Foo()
{
    List<double> myList = new List<double>(1024);
    myList.Add(1.0);
    myList.Add(2.0);
    ....

    myList.Clear(); <-- what is the list's 'initial' capacity now?
}

What will be myList's capacity after calling myList.Reset()? Is it 1024?

2 Answers
Related