Example:
using System; using System.Linq; using System.Collections.Generic;
class LinqCountWithConditionExample { public static void Main(string[] args) {
int[] nums = { 51,52,53,54,52,63,72,52,110 };
var resutls = nums.Count(n => n == 52);
Console.WriteLine(“Number of times 52 appears:” + resutls);
Console.ReadLine();
} }
Output: Number of times 52 appears:3
[...]
