Question
Write a C++ program that creates an integer array having 30 elements. Then, implement 4 functions as shown below: (A) First, call the function Read_Array(
Write a C++ program that creates an integer array having 30 elements. Then, implement 4 functions as shown below: (A) First, call the function Read_Array( ) by passing the array from the main program. The Read_Array( ) function should get input from the user for each array element. (B) Next, call the function Find_Sum( ) and pass the array from the main( ) function. The Find_Sum( ) function should calculate the sum of values stored in the array and then print the sum on the screen. (C) After that, the main( ) should call the function Find_Greater( ) by passing the array. The function Find_Greater( ) Then, it should find and print a number which is greater among all. (D) In the end, the main( ) should call the function Display_Above_Avarage( ) by passing that array. The function should first find the average of array values and then display only those elements which are greater than average.
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started