Question: Write a short program that reads in a positive integer from the user that says how many numbers to enter, then enters each number (assume
Write a short program that reads in a positive integer from the user that says how many numbers to enter, then enters each number (assume valid inputs), then print out some statistics Printout must include mean, median, and mode and mean median and mode must be in separate functions that rectum the result. Function prototypes are below. You may assume a sort function exists as well as mean. Just write median and mode and the rest of main. A helper function fill Array is provided, it takes in an array as an argument and fills with the integer data needed (not in order and no repeating values). int mean (int array[], int size)1//Already exists int median (int array[] int size): int mode (int array[] int size): int sort (int array[] int size)://Already exists void fill Array (int array[] int size)//Already exists int main(){int numElements1 printf ("Enter number of elements:): scanf (d* shunt elements)://create the array//call functions and print results to user
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
