[Beginner] Arrays of variable length in c#

  • Thread starter Thread starter Flix
  • Start date Start date
F

Flix

In C++ the standard classes vector and deque define an array of real-time
variable length (items can be appended or removed to a vector, modifying its
length).

Is there a class in C# that performs the same functionality (probably a
ListBox control can perform it, but it's not a standard solution) ?
 
Is there a class in C# that performs the same functionality (probably a
ListBox control can perform it, but it's not a standard solution) ?

System.Collections.ArrayList



Mattias
 
Flix said:
In C++ the standard classes vector and deque define an array of real-time
variable length (items can be appended or removed to a vector, modifying its
length).

Is there a class in C# that performs the same functionality (probably a
ListBox control can perform it, but it's not a standard solution) ?

ArrayList is probably what you're after.
 
Hi,

See if ArrayList can fulfill your requirements.

In C++ the standard classes vector and deque define an array of real-time
variable length (items can be appended or removed to a vector, modifying its
length).

Is there a class in C# that performs the same functionality (probably a
ListBox control can perform it, but it's not a standard solution) ?
 
Flix said:
In C++ the standard classes vector and deque define an array of real-time
variable length (items can be appended or removed to a vector, modifying its
length).
Is there a class in C# that performs the same functionality (probably a
ListBox control can perform it, but it's not a standard solution) ?


Shiva said:
Hi,
See if ArrayList can fulfill your requirements.

Other collection classes can be found in System.Collections.

And if you wait long enough for the next .NET standard, you will enjoy
template versions of these classes.

Cheers,
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top