Question: please help me to solve this with C++ Question The arithmetic mean of N numbers is the sum of all the numbers, divided by N.

please help me to solve this with C++ Question The arithmetic meanplease help me to solve this with C++

Question The arithmetic mean of N numbers is the sum of all the numbers, divided by N. The mode of N numbers is the most frequently occurring number. Write an algorithm to find the mean and mode of a set of given numbers. Input The first line of input consists of an integer-inputNum, representing the number of elements in the set (N). The next line consists of N spaceseparated integers representing the elements of the given set. Output Print K space-separated integers where the first number is the mean of the input numbers and the second number is the mode (where K=2 ). Note If mean calculated is in decimal, print its floor value (Floor is the greatest integer less than or equal to that number: floor [2.4]=2 ). Example Input: 5 12732 Output: 32

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!