You use Microsoft Visual Studio 2010 and Microsoft .NET Framework 4 to create an application. The
application connects to a Microsoft SQL Server database. You create the classes shown in the
following exhibit.
You add the following code segment to the application. (Line numbers are included for reference
only.)
01Public Sub QueryPlayers(leagues As List(Of League))
02
03End Sub
You create a LINQ query to retrieve a collection of Player objects. You need to ensure that the
collection includes all the players from each team and every league. Which code segment should you
insert at line 02?
A.
Dim query As var = leagues.[Select](Function(l As ) l.Teams.[Select](Function(t As ) t.Players))
E.
Dim query As var = leagues.[Select](Function(l As ) l.Teams.SelectMany(Function(t As ) t.Players))
C.
Dim query As var = leagues.SelectMany(Function(l As ) l.Teams.SelectMany(Function(t As )
t.Players))
D.
Dim query As var = leagues.SelectMany(Function(l As ) l.Teams.[Select](Function(t As ) t.Players))