Mid LINQ

Replace foreach with LINQ?

Replace foreach with LINQ

employees.ForEach(e => Console.WriteLine(e.Name));

Follow :

✅ This is not LINQ but syntactic sugar with List<T>.ForEach.

More from LINQ Tutorial

All questions for this course