How to get MAX value from Dictionary?

前端 未结 8 2291
独厮守ぢ
独厮守ぢ 2020-12-30 19:16

I have

Dictionary d = new Dictionary();

How I can get an Guid which has MAX

8条回答
  •  予麋鹿
    予麋鹿 (楼主)
    2020-12-30 20:02

    Guid implements IComparable, so:

    d.Keys.Max()
    

    Also it is not clear why one would want to do so...

提交回复
热议问题