Dim ary() As String = {"a","b","ab","bc","a","b"} Dim dic As new Dictionary(Of String, Integer) For Each s As String In ary If dic.ContainsKey(s) = False Then dic.Add(s, 1) Else dic(s) = dic(s) + 1 End If Next
For Each k As String In dic.Keys If dic(k) > 1 Then output.show(k) End If Next