c# order preserving data structures
- by Oren Mazor
Oddly enough, MSDN has no information on the order preserving properties of data structures. So I've been making the assumption that:
Hashtable and Hashset do not preserve the insertion order (aka the "hash" in there is a giveaway)
Dictionary and List DO preserve the insertion order.
from this I extrapolate that if I have a Dictionary<double,double> foo that defines a curve, foo.Keys.ToList() and foo.Values.ToList() will give me an ordered list of the scope and domain of that curve without messing about with it?