标签: c# linq
下面的代码抛出sequence does not contain the matching element。
sequence does not contain the matching element
var inavailableous = userOuIds.Any(n => ("," + item.AvailableOUs + ",").Contains(n));
其中userOuIds为List<string>的值为,1,,而item.AvailableOUs为string的值为1,2,3,4,5,6。
userOuIds
List<string>
,1,
item.AvailableOUs
string
1,2,3,4,5,6
请帮助我代码出了什么问题?