How about the List.FindIndex Method:
int index = myList.FindIndex(a => a.Prop == oProp);
This method performs a linear search; therefore, this method is an
O(n) operation, where n is Count.
If the item is not found, it will return -1
How about the List.FindIndex Method:
int index = myList.FindIndex(a => a.Prop == oProp);
This method performs a linear search; therefore, this method is an
O(n) operation, where n is Count.
If the item is not found, it will return -1