1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
marysya [2.9K]
2 years ago
5

4.17 LAB: Varied amount of input data ( C++)

Computers and Technology
1 answer:
stiv31 [10]2 years ago
5 0

Answer:

Written in C++

#include<iostream>

using namespace std;

int main()

{

int num;

int sum = 0;

cout<<"Input: ";

cin>>num;

int count = 0;

int max = 0;

while(num >= 0)

{

 sum+=num;

 cin>>num;

 count++;

 if(num>=max){

  max = num;

 }

}

cout<<(sum/count)<<endl;

cout<<max<<endl;

return 0;

}

Explanation:

<em>I've added the full source code as an attachment where I use comments as explanation.</em>

<em>See Attachment</em>

Download cpp
You might be interested in
Give five functions of Windows​
Nata [24]

Answer:

Explanation:

It knows how to remember data and where to find that data. In other words, it knows how the raw memory works. (RAM).

It understands how to make a program run within the confines of its logical steps in an order that makes the program work the way the user intends.

It can be made to display short cuts, or any icon or picture (not an obvious talent).

It can search for unwanted intruders like ads or viruses.

It can can time events even to the point of getting your coffee ready for you with the proper add on.

6 0
3 years ago
What would you do if you experienced academic frustrations in school? Check all that apply.
kipiarov [429]
I think it is all of them :))
6 0
2 years ago
Read 2 more answers
What software can be used for remote operation of a sunsdr2 dx?.
Rasek [7]

Answer:

Install the ExpertSDR2 Remote Client software on your PC. Download the client here. You can also access your device via any web browser

8 0
2 years ago
The incident results in huge losses of revenue as a result their mobile app service is withdrawn. Investigators discovered a vul
zlopas [31]

Answer:

The attackers used the code injection

Explanation:

<em>Because, the HMTL5 allows data and code to be mixed together, making code injection attacks possible. </em>

6 0
3 years ago
PLEASE HELP ASAP! WILL MARK BRAINLIEST IF THE ANSWER IS CORRECT! I NEED HELP WITH THE 3RD ONE!
Bogdan [553]

Answer:

Explanation:

.1 Display all information from the customer table for all customers that have a balance that is greater than the average balance.

2. Display all information from the rep table for all representatives that have a rate which is equal to the minimum rate for representatives.

3. Display each unique description and price (no duplicates) for all parts that have a quoted price that is greater than the average quoted price for all parts ordered.

4. List all streets where either a customer or a representative is located

5 0
3 years ago
Other questions:
  • Harry needs to use a type of graph in a spreadsheet to show variations in data over a specific period. What type of graph or cha
    11·2 answers
  • If you delete a file from removable media, it is stored in the recycle bin where you can recover it until you empty the recycle
    13·1 answer
  • Which of the following is software? : Monitor Mouse Windows Keyboard Printer
    13·1 answer
  • When you park on a hill, think about which way _____.
    6·2 answers
  • What is the purpose of a email
    11·2 answers
  • List all the components of a computer
    14·2 answers
  • What feature is available to add a suggestion in the margin of someone else's document?​
    15·1 answer
  • The ___________ method returns the length of an array.
    11·2 answers
  • How do i unblock a website on a school computer if a school blocks it?
    5·1 answer
  • What happens if part of an ftp message is not delivered to the destination?
    14·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!