What will be the result of the query?

Posted by: Pdfprep Category: GSSP-.NET Tags: , ,

You work as a Software Developer for ABC Inc. The company uses Visual Studio .NET

2008 as its application development platform. You create an ASP.NET Web application using .NET Framework 3.5. The application is a library application that catalogs Classes and books. The application contains a DataContext object named Classes and a related line of business object named Books. The Classes DataContext object is queried by using the following LINQ query: var query = from class in Classes where class.Books.All(b => b.Price <= 50) select class;

You have to find out the result that will be returned from the query.

What will be the result of the query?
A . All books that have a price greater than or equal to 50.
B . All books that have a price less than or equal to 50.
C . All Classes that have the price of the related book greater than or equal to 50.
D . All Classes that have the price of the related book less than or equal to 50.

Answer: D

Leave a Reply

Your email address will not be published.