subject

2.31 lab: simple statistics part 1 given 3 integers, output their average and their product, using integer arithmetic. ex: if the input is: 10 20 5 the output is: 11 1000 note: integer division discards the fraction. hence the average of 10 20 5 is output as 11, not 11.6667. note: the test cases include three very large input values whose product results in overflow. you do not need to do anything special, but just observe that the output does not represent the correct product (in fact, three positive numbers yield a negative output; wow). submit the above for grading. your program will fail the last test cases (which is expected), until you complete part 2 below. part 2 also output the average and product, using floating-point arithmetic. output each floating-point value with two digits after the decimal point, which can be achieved by executing cout < < fixed < < setprecision(2); once before all other cout statements. ex: if the input is: 10 20 5 the output is: 11 1000 11.67 1000.00 note that fractions aren't discarded, and that overflow does not occur for the test case with large values.

ansver
Answers: 1

Another question on Computers and Technology

question
Computers and Technology, 22.06.2019 01:30
What “old fashioned” features of checking accounts is p2p replacing
Answers: 3
question
Computers and Technology, 22.06.2019 21:30
Im doing this last minute and literally none of my neighbors or people that my dad works with use excel so if anyone could me make up an example
Answers: 1
question
Computers and Technology, 22.06.2019 23:30
For her science class, elaine is creating a presentation on weather in the united states. she wants to make the presentation beautiful and interesting by drawing simple cloud or wave shapes. which is the best way for elaine to draw these shapes?
Answers: 1
question
Computers and Technology, 23.06.2019 04:31
Which of the following is not a way in which trees benefit the environment? a. they remove a significant amount of carbon dioxide from the atmosphere. b. they remove a significant amount of oxygen from the atmosphere. c. their roots hold soil in place, reducing rates of erosion. d. they remove ozone and particulates from the atmosphere. select the best answer from the choices provided a b c d
Answers: 1
You know the right answer?
2.31 lab: simple statistics part 1 given 3 integers, output their average and their product, using...
Questions
question
History, 15.10.2019 18:30
question
History, 15.10.2019 18:30
Questions on the website: 13722363