Remove Dups From Array List


private static string[] RemoveDuplicates(ArrayList arrList)
{
        HashSet<string> Hset = new HashSet<string>((string[])arrList.ToArray(typeof(string)));
        string[] Result = new string[Hset.Count];
        Hset.CopyTo(Result);
        return Result;
}

Comments (0)