close
'過濾重複字串 或數字
Dim ary() As Integer = {2, 4, 1, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3}
' 使用預設的相等比較子來比較值,以便從序列傳回獨特的項目。
For Each i As Integer In ary.Distinct.ToArray
MessageBox.Show(i)
Next
文章標籤
全站熱搜
'過濾重複字串 或數字
Dim ary() As Integer = {2, 4, 1, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3}
' 使用預設的相等比較子來比較值,以便從序列傳回獨特的項目。
For Each i As Integer In ary.Distinct.ToArray
MessageBox.Show(i)
Next