This document provides instructions for an activity to write a program that calculates the average and maximum of an input of varying integer amounts. The program takes in integers separated by spaces as input, converts them to integers, sums them, and divides by the length to calculate the average. It also tracks the largest integer and prints both the average and maximum as output.
This document provides instructions for an activity to write a program that calculates the average and maximum of an input of varying integer amounts. The program takes in integers separated by spaces as input, converts them to integers, sums them, and divides by the length to calculate the average. It also tracks the largest integer and prints both the average and maximum as output.
This document provides instructions for an activity to write a program that calculates the average and maximum of an input of varying integer amounts. The program takes in integers separated by spaces as input, converts them to integers, sums them, and divides by the length to calculate the average. It also tracks the largest integer and prints both the average and maximum as output.
Instructor note: Note: this section of your textbook contains activities that you will complete for points. To ensure your work is scored, please access this page from the assignment link provided in Blackboard. If you did not access this page via Blackboard, please do so now. Statistics are often calculated with varying amounts of input data. Write a program that takes any number of integers as input, and outputs the average and max. Ex: If the input is: 15 20 0 5 the output is: 10 20