C Sharp (C#) - LINQ Fundamentals
Find the issue in this code:
var list = new List<string> { "dog", "cat", "bird" };
var sorted = list.OrderByDescending();var list = new List<string> { "dog", "cat", "bird" };
var sorted = list.OrderByDescending();OrderByDescending requires a lambda expression to select the key for sorting.OrderByDescending() without any argument, causing a compile error.15+ quiz questions · All difficulty levels · Free
Free Signup - Practice All Questions