开发者

Get Unique record from one list that not match with other?

Hi I开发者_JAVA百科 have two list I want to get Unique record from first list that not match with other.

Example

List = [1,2,3,4,5,6,7]

List = [1,2,3,4,5,8]

According to my need output should be like this [6,7].

Please suggest me how it will be done?


IEnumerable<int> result = list1.Except(list2);


You can use Except

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜