1. Declare a struct called Empinfo that contains: string name, string id, double "reviews, and double average. 2. Declar
Posted: Fri May 20, 2022 2:54 pm
1. Declare a struct called Empinfo that contains: string name, string id, double "reviews, and double average. 2. Declare a pointer to the Empinfo struct called employees. 3. Allocate memory on the heap (dynamically allocate memory for an array) for 10 Empinfo structs and make employees to point at the start of the array. Make sure to allocate memory for 4 review scores for each element of the employees array. 4. Assume that the array is populated, that is all the elements have valid values stored in them (that is there is no need for any input). Write a function called calcAverage() that takes employees array and its size as arguments, and calculates the average review score of each employee.