Company: Cvent Full stack developer experience 5 years_12may
Difficulty: medium
Process Student Data Problem Description Data of N students is given: each student's name, the scores they obtained in various subjects, their city and their state. Write a function processStudentData that takes the array of student records and builds a report with the following properties: totalStudents : the total number of students. averageScores : the average score of each student (the mean of that student's own scores), in input order, rounded to 2 decimal places. uniqueCities : the unique cities where students reside, in order of first appearance. studentsFromState : for each state, the names of the students from that state, in input order. (correction -- the original statement words item 2 as "average scores for each subject across all students", but its own sample and explanation average each student's scores: Alice (85 + 90 + 78) / 3 = 84.33 , Bob 88 , Charlie 86.33 . Per-subject averages would print 88.33,84.67,85.67 , which contradicts the sample, so the per-student reading