Question: Can you help me write this program? array stuct.c contains the basis for writing a program to determine the min, max, and average of ages
array stuct.c contains the basis for writing a program to determine the min, max, and average of ages and heights using an array of structures. of the function init.array0. The prototype is given in array-struct.h. 2. Write a function that finds the min of the ages. Return the index. 3. Write a function that finds the min of the heights. Return the index 4. Write a function that finds the max of the ages. Return the index. 5. Write a function that finds the max of the heights. Return the index. 6. Write a function to find the average age of the test subjects. Return the average age. 7. Write a function to find the average height of the test subjects. Return the average height 8. Wirite a finction to print an individual structure. Returns nothing 9. Print each structure item that corresponds to the minimum age, the maximum age, the minimum height, and the maximum height. 10. Print the average age and the average height of the test subjects. 11. Run with the provided data in array.struct.c and save it as array.struct.script array_struct.c array_ struct.h 2 #define ARRAY-STRUCT-H- 3 4 5#define szE 5 6 7 struct data tc 8 9 int age; age of the subject 1 int height height of subject in tnches char subject:one capttaL Letter td for subject m/ 12 4 5 votd init array(struct data t data[l, nt tndex. char td, tnt years, tnt nches 16 17 18 #endtf array struct.c 1#include 2 #include "array-struct. h"
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
