Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Write a program to prompt the user for eight (8) float values, and store the data in the float array a[] in the main()

Write a program to prompt the user for eight (8) float values, and store the data in the float array a[] in the main() function. The program will calculate the average using the average() function, which accepts the relevant input parameters, and outputs the result to the terminal screen. Example, Enter 8 float values: 1 2 3 4 5 6 7 8 Average = 4.50 Enter 8 float values: 4.6 5.3 1.7 8.3 2.2 5.5 6.2 4.7 Average 4.81

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Java Programming

Authors: Joyce Farrell

9th edition

1337397075, 978-1337397070

More Books

Students also viewed these Programming questions

Question

Where is the position?

Answered: 1 week ago

Question

Find AB, given AB is not defined: A = [619] B= 52

Answered: 1 week ago