linq check if exists in list code example
Example: linq check if exists in list
using System.Linq;
...
bool has = list.Any(cus => cus.FirstName == "John");
using System.Linq;
...
bool has = list.Any(cus => cus.FirstName == "John");