The below code when checked in "Add watch" window shows the right value (100), but the value is not assigned to variable _countVar, the value is 0 which is incorrect.
Can someone tell me what is wrong in my code:
string _strVariable = "New York";
var _countVar = nestList
.SelectMany((List<object> w) => w)
.Count(w => w == _strVariable);