Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Write a C++ program that calculates an average of several integers entered by the user. It first prompts the user to enter the number of

Write a C++ program that calculates an average of several integers entered by the user. It first prompts the user to enter the number of integers she wants to average, then allows the user to enter the integers one by one, then calculates and displays the result as a floating point number. You must use an array to store the integers; use a loop to fill the array; write a separate function called "average()", which will be called from the main function, and to which the array and its size will be passed as two parameters. You will need to use a loop inside the average function, as well as cast an integer into a float to get a floating point result

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

Secrets Of Analytical Leaders Insights From Information Insiders

Authors: Wayne Eckerson

1st Edition

1935504347, 9781935504344

More Books

Students also viewed these Databases questions