Question: Make a program that creates an array (intArray) that holds 50 values. Make the following functions (and use them): fill the array with a given

Make a program that creates an array (intArray) that holds 50 values. Make the following functions (and use them):

  • fill the array with a given number of random integers between a given minimum and maximum.
  • with the array as input, find the minimum value, return the minimum to main
  • with the array as input, find the maximum value, return the maximum to main
  • with the array as input, find the sum of the values, return the sum to main
  • with the array as input, print all the values in the array - pass in a variable that lets the function know how many values to print per line, pass in a variable that lets the function print either to cout or to a file.

in main, call all the functions:

  1. fill the array with 50 random integers between -75 and 200
  2. print the array to cout
  3. print the array to yourname.txt
  4. print the minimum
  5. print the maximum
  6. print the sum
  7. print the average

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!