Linq Query:
Total 3 Items which are less then 10
//Count Conditional
int[] intNumbers = { 1, 2, 3, 55, 99, 74, 102 };
int total = intNumbers.Count(n => n < 10 ); //Total 3 Items which are less then 10
Console.WriteLine(total);
//
Output:3
Total 3 Items which are less then 10
0 comments:
Post a Comment