Question: Mandatory Instructions Write a C++program your main function. Pass arrays or other variables as needed to the functions you write. For each task below decide


Mandatory Instructions Write a C++program your main function. Pass arrays or other variables as needed to the functions you write. For each task below decide what arguments need to be passed to the function. Then add a function prototype before the main function, a function call in the main function and the function definition after the main function that will manipulate arrays in various ways. Include the array declarations shown below in const int ARRAYSIZE8 int data [ARRAYSIZE]; int numbers [ARRAYSIZE]148, 23, 19, 62, 37, 21, 8, 35 Task 1: Write a function that assigns multiples of 5 to each of the elements in the data array. For example, datal0) should be set to 0, dataI] should be set to 5, then 10, 15 and so on. You must use a for loop to assign the values to the array elements. Use a second for loop to display the subscript and the contents of each element of the array. The first few lines should look like this: Ele# data array value 2 10 Task 2: Write a function to find and return the smallest value in the numbers array. Use a for loop in the function to do this. The main function should display this value Task 3: Write a function to copy all of the values in the numbers array to the corresponding elements in the data array using a for loop (i. e., copy the value in element 0 of the numbers array to element 0 of the data array and so on Use a second for loop to display the subscript and the contents of each element of the two arrays. The first few lines should look like this: Ele# data array numbers array 23 23
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
