imports System.Collection.generic
public function Tri(byval pSrc as ilist(of string)) as list(of string)
dim lSortLst as new sortedlist(of string,string)
for each lStr as String in psrc
lsortLst.add(lstr,lStr)
next
dim lLst as new list(of string)
for i as integer=0 to lSortList.count-1
llst.add(lSortList.Values(i))
next
return lLst
end function
'Utilisation :
Dim lTabTrié as list(of string)=Tri(TableauNontrié)
TableauNonTrié peut être des types :
- string()
- list(of string)
- Tout autre type implémentant IList(of string)