Exercise 1 Write and test a function that returns the index of the minimum value among the first n elements of a given array : float min(float a[], int n); Exercise 2 Write and test the following function: double stddev(double x[], int n); The function returns the standard deviation of a dataset of n numbers x0, ..., xn-1 defined by the formula s = sqrt(Sum_{i=0}^{n-1}[ (xi-mean)^2] / (n-1)); Exercise 3 Copy the files sortArray.{h,cpp} into your working directory. The files contain statements and definitions of some useful functions to manipulate array. Write a program that generates N (chosen by the user) random numbers between 1 and Nmax (chosen by the user) and stores them in a matrix of size N. Using the functions contained in the array handle: - print the generated matrix - perform average, median and mode calculations of the elements of the matrix - print the histogram of the frequencies of the individual values Execution example: ./usesortArray   Tell me the maximum random number you want to generate 15   Tell me the size of the Array of random numbers 100   Here is the matrix: 16 1 11 11 10 15 9 9 16 11 7 10 14 15 7 3 16 9 14 5 1 2 8 2 4 6 3 5 8 13 15 7 13 9 1 6 7 9 15 7 3 5 16 1 3 7 3 2 15 16 6 15 1 13 16 4 3 2 9 10 15 7 16 11 15 16 1 6 8 15 12 11 3 11 11 5 1 13 6 15 13 12 13 13 8 12 1 10 14 9 3 12 15 2 6 13 1 6 2 9 Average is: 8.72 Median is : 9 Mode is : 15 Histogram of the frequencies: 0 1 ********* 2 ****** 3 ******** 4 ** 5 **** 6 ******* 7 ******* 8 **** 9 ******** 10 **** 11 ******* 12 **** 13 ******** 14 *** 15 *********** Exercise 2 Copy the files searchArray.{h,cpp}: which contain functions for the linear and binary search of a given value in an array. Write a program that generates an array and looks for a value chosen by the user in the created array with the linear search method. g++ searchArray.cpp useLinearSearchArray.cpp -o useLinearSearchArray ./useLinearSearchArray Exercise 3 Write a program that generates an array and looks for a value chosen by the user in that array with the binary search method. Remember that the matrix must be ordered. Use the bubbleSort function implemented in sortArray.cpp function for this purpose. g++ searchArray.cpp sortArray.cpp useBinarySearchArray.cpp -o useBinarySearchArray ./useBinarySearchArray