Language Integrated Query (LINQ) Question: Download LINQ PDF

How can you find average of student marks from student tables (Columns are StudentID, Marks)?

Tweet Share WhatsApp

Answer:

(C#)

Public void LinqToSqlAverage()
{
var query = (from p in db. student. Marks).Average();
Console.WriteLine(q);
}

Download LINQ PDF Read All 35 LINQ Questions
Previous QuestionNext Question
Write a Program for Concat to create one sequence of Data Rows that contains DataTabless Data Rows, one after the other?What is “OfType” in linq?