Answers for "find number of elements in list c#"

C#
2

c# count specific element in list

// lstSlots = new List<int> { 1, 1, 0 }
lstSlots.Count(n => n == 1)	// returns 2
Posted by: Guest on September-08-2021
1

c# find element in list of list

var element = (from sublist in userList
               from item in sublist
               where item.uniqueidentifier == someid
               select item).FirstOrDefault();
Posted by: Guest on June-24-2020

Code answers related to "find number of elements in list c#"

C# Answers by Framework

Browse Popular Code Answers by Language