我正在使用System.Collections.Generic.Dictionary<string, string>.
System.Collections.Generic.Dictionary<string, string>
我想从这本词典中返回第一个键.我试过,dic.Keys[0]但我在Keys属性上唯一的东西(它是一个KeyCollection对象)是一个枚举器.
dic.Keys[0]
Keys
KeyCollection
我是否必须通过所有键来枚举第一个?
c#
c# ×1