A Visual Basic CodeDim hsQ = From hspt In hospitals
Order By hspt.County, hspt.City
Group hspt By hspt.County Into hsptGroup = Group
C# Codevar hsQ = from hspt in hospitals
orderby hspt.County, hspt.City
group hspt by hspt.County;
B Visual Basic CodeDim hsQ = From hspt In hospitals
Order By hspt.County
Group hspt By hspt.County Into hsptGroup = Group
Order By hsptGroup.Last.City
C# Codevar hsQ = from hspt in hospitals
orderby hspt.County
group hspt by hspt.County into hsptGroup
orderby hsptGroup.Last().City
select hsptGroup;
C Visual Basic CodeDim hsQ = From hspt In hospitals
Order By hspt.County, hspt.City
Group hspt By hspt.County Into hsptGroup = Group
Order By hsptGroup.First.County
C# Codevar hsQ = from hspt in hospitals
orderby hspt.County
group hspt by hspt.County into hsptGroup
orderby hsptGroup.Key
select hsptGroup;
D Visual Basic CodeDim hsQ = From hspt In hospitals
Order By hspt.City
Group hspt By hspt.County Into hsptGroup = Group
Order By hsptGroup.First.County
C# Codevar hsQ = from hspt in hospitals
orderby hspt.City
group hspt by hspt.County into hsptGroup
orderby hsptGroup.First().County
select hsptGroup;