Question: Please Explain step by step also. Thank you Given the code: srand(time(NULL)); int CAPACITY = 10; int a[CAPACITY]; Output Example 5 6 2 5 292
Please Explain step by step also. Thank you
Given the code: srand(time(NULL)); int CAPACITY = 10; int a[CAPACITY]; Output Example 5 6 2 5 292 6 8 9 5.4 1. Write a loop to store random values from 0 to CAPACITY-1 inclusive into the array. 2. Write a loop to print the array and calculate the average of all values. 3. Write a line of code to print the calculated average to the console
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
