Consider the data type Elev, defined as follows:
struct Elev {
char nume[40];
int g[4];
int ng;
double medie;
};where nume is the student name, g is the grades array, ng is the number of grades (the same for all students), and medie is the arithmetic mean of the grades.
Read from standard input three natural numbers n, k, and m, representing the number of students, how many students to include in the ranking, and how many grades each student has. The data for n students follows (name and m grades).
Compute the arithmetic mean for each student, then print the top k students in descending order of their average. If two students have the same average, the one whose name is lexicographically smaller (compare with strcmp) is printed first. If k > n, print all n students.
The average is printed with exactly two decimal places.