nerdexam
Microsoft

70-516 · Question #162

70-516 Question #162: Real Exam Question with Answer & Explanation

Sign in or unlock 70-516 to reveal the answer and full explanation for question #162. The question stem and answer options stay visible for context.

Question

You need to write a LINQ query that can be used against a ContosoEntities context object named context to find all parts that have a duplicate name. Which of the following queries should you use? (Each correct answer presents a complete solution. Choose two).

Options

  • Acontext.Parts.Any(p => context.Parts.Any(q => p.Name == q.Name));
  • Bcontext.Parts.GroupBy(p => p.Name).Where(g => g.Count() > 1).
  • Ccontext.Parts.SelectMany(p => context.Parts.
  • Dcontext.Parts.Where(p => context.Parts.Any(q =>

Unlock 70-516 to see the answer

You've previewed enough free 70-516 questions. Unlock 70-516 for full answers, explanations, the timed quiz mode, progress tracking, and the master PDF. Question stem and options stay visible so you can still see what's on the exam.

Full 70-516 Practice