Differences between Single and First in C#
In this tutorial we will take a closer look at few methods used to retrieve items from collections: Single() SingleOrDefault() First() FirstOrDefault() Firstly, we will prepare our list: List<Student> students = new List<Student>(); students.Add(n...
Jul 12, 20212 min read153
