(.NET) List.FindAll

C#/Winform 2017. 4. 15. 22:06
728x90

List<string> testList = new List<string>() { "aa", "bb", "cc", "dd" };

List<string> difList = testList.FindAll(delegate(string s) { return !s.Equals("aa"); }); 

결과

difList

  [0] "bb" string
  [1] "cc" string
  [2] "dd" string 

728x90
Posted by kjun.kr
,