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
FinnZ [79.3K]
3 years ago
5

rray testGrades contains NUM_VALS test scores. Write a for loop that sets sumExtra to the total extra credit received. Full cred

it is 100, so anything over 100 is extra credit. Ex: If testGrades
Computers and Technology
1 answer:
diamong [38]3 years ago
4 0

Answer:

Replace

/* Your solution goes here */

with

sumExtra = 0;

for (i =0; i<NUM_VALS;i++){

if(testGrades[i]>100){

sumExtra = sumExtra - testGrades[i] + 100;

}

}

Explanation:

This line initializes sumExtra to 0

sumExtra = 0;

The following is a loop from 0 to 3

for (i =0; i<NUM_VALS;i++){

The following if condition checks if current array element is greater than 100

if(testGrades[i]>100)

{

This line calculates the extra credit

sumExtra = sumExtra - testGrades[i] + 100;

}

}

<em>See attachment for complete question</em>

Download docx
You might be interested in
Which of the following does not make a good analysis class? (Points : 6) its name reflects its intent
satela [25.4K]

Answer:it has high coupling

Explanation: Coupling is the property in the field of computer program that is defined as the functions ,data and  codes of the program are dependent on each other and cannot be changed independently if requires. Thus,high amount of coupling is not considered as good factor due to high interdependence. Loose coupling can be still permitted.

Other options are correct because name of the class should reflect the purpose and well defined responsibilities should be present, modeling of certain component and high cohesion means keeping similar functions togather is also required. So, the only bad factor is high coupling

6 0
2 years ago
Each time an end user clicks a hyperlink, the browser generates a(n) _____ page request that is sent to the designated web serve
irina1246 [14]

Answer:

HTTP GET

Explanation:

The Hypertext Transfer Protocol (HTTP) is designed to enable communications between clients and servers and it uses the GET method to request data from the specified resource using the TCP/IP Internet protocol.

4 0
2 years ago
What do you understand by cloud computing? list the advantages of clould computing.​
LenaWriter [7]

Answer:

Cloud infrastructures support environmental proactivity, powering virtual services rather than physical products and hardware, and cutting down on paper waste, improving energy efficiency, and (given that it allows employees access from anywhere with an internet connection) reducing commuter-related emissions.

Explanation:

3 0
2 years ago
Read 2 more answers
The ____ provides access to the Internet may also be internal.
dmitriy555 [2]
Local area network (LAN)
7 0
2 years ago
Read 2 more answers
Blank Are input instructions you give to a computer
kotegsom [21]

Explanation:

A computer is a machine that can be programmed to accept data (input), process it into useful information (output), and store it away (in a secondary storage device) for safekeeping or later reuse. The processing of input to output is directed by the software but performed by the hardware.

4 0
2 years ago
Other questions:
  • Assume that the following code segment C is executed on a pipelined architecture that will cause data hazard(s): Code segment C:
    9·1 answer
  • How many bytes of information can be stored on a hard drive?
    7·1 answer
  • What was the original motivation for developing the internet?
    7·1 answer
  • Every brand of computer has its own binary language, called
    14·1 answer
  • This program will store roster and rating information for a soccer team. Coaches rate players during tryouts to ensure a balance
    5·1 answer
  • What did major networks do to combat audience erosion in the 1990s?
    15·1 answer
  • Vegetable farming is a good source of income explain this statement<br>​
    5·1 answer
  • The Python language uses a compiler which is a program that both translates and executes the instructions in a high-level langua
    15·1 answer
  • when you sent email your email can be set to automatically keep a copy where do you find these copies​
    13·1 answer
  • write code to print out all combinations of pairs of numbers 1 through m and 1 through n, separated by a comma
    10·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!