Collection that allows only unique items in .NET?

后端 未结 7 2463
天涯浪人
天涯浪人 2020-12-13 16:35

Is there a collection in C# that will not let you add duplicate items to it? For example, with the silly class of

public class Customer {
    public string F         


        
相关标签:
7条回答
  • 2020-12-13 17:30

    You can try HashSet<T>

    0 讨论(0)
提交回复
热议问题