Linq Query:
Output:
int[] intNums = { 1, 2, 3, 4 }; var myNums = intNums.FirstOrDefault(s => s == 5); Console.WriteLine(myNums); //Output will be 0 [Not Found]
Output:
0
0 comments:
Post a Comment