📅  最后修改于: 2022-03-11 14:45:41.143000             🧑  作者: Mango
// dict is Dictionary
Foo[] foos = new Foo[dict.Count];
dict.Values.CopyTo(foos, 0);
// or in C# 3.0:
var foos = dict.Values.ToArray();