Find an element in List of List, c#
- by Sandy
Hi,
I have a list of lists as below:
List<List <T> > userList
Class T { string uniqueidentifier, string param2, int param2}
I have a uniqueidentifier and i need to find the element T in the list that has the same 'uniqueidentifier' value.
I can do it using two 'foreach' loops. This does not seem to be nice way doing things. I guess there should be some inbuilt method like 'Find' that does the same thing and is highly optimized.