Foxtable(狐表)用户栏目专家坐堂 → sort 排序


  共有2634人关注过本帖树形打印复制链接

主题:sort 排序

帅哥,在线噢!
有点蓝
  1楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:超级版主 帖子:110727 积分:563555 威望:0 精华:9 注册:2015/6/24 9:21:00
  发帖心情 Post By:2023/12/10 21:41:00 [显示全部帖子]

Dim names() As String = {"赵沿骅", "赵思群", "范丙刚", "徐红", "范瑞"}
Dim Marks() As Integer = {99, 90, 85, 89, 86}
Dim d As New SortedDictionary(Of Integer, String)
For i As Integer = 0 To Marks.Length - 1
    d.Add(Marks(i), names(i))
Next

For i As Integer = d.Keys.Count - 1 To 0 Step - 1
    Output.Show(d.Keys(i) & "=" & d(d.Keys(i)))
Next 

 回到顶部