Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,6 @@ from student in students
group student by student.Last[0];
//</snippet10>



// This query could be easily modified to group by the entire last name.
//<Snippet11>
// Group students by the first letter of their last name
Expand All @@ -39,7 +37,6 @@ orderby g.Key
select g;
//</snippet11>
Console.WriteLine("The SimpleGroup method produces this output:\r\n");


//<snippet12>
// Iterate group items with a nested foreach. This IGrouping encapsulates
Expand All @@ -56,10 +53,9 @@ orderby g.Key
}
//</snippet12>


//<Snippet13>
// Same as previous example except we use the entire last name as a key.
// Query variable is an IEnumerable<IGrouping<string, Student>>
// Same as previous example except we use the entire last name as a key.
// Query variable is an IEnumerable<IGrouping<string, Student>>
var studentQuery3 =
from student in students
group student by student.Last;
Expand Down