Answers for "c# max sequence contains no elements"

C#
0

c# max sequence contains no elements

return collection.Any() ? collection.Max(c => c.Value) : 0;
// Or replace 0 with null or whatever other default 
// value you'd like to return.
Posted by: Guest on March-09-2020

C# Answers by Framework

Browse Popular Code Answers by Language