laiban123456 laiban123456
  • 02-07-2020
  • Computers and Technology
contestada

Q) write a code that reads a given array and calculates the SUM of its elements.

Respuesta :

Plus16463574585
Plus16463574585 Plus16463574585
  • 02-07-2020

Answer:

See the explanation below.

Explanation:

If don't know which language you are using, but the basic pseudo code for this problem will be:

variable sum = 0;

for ( i = 0;  i < array.length;  i ++) {

    sum += array[i];

}

print(sum);

Best Regard!

Answer Link

Otras preguntas

At what type of plate boundary do compression and subduction take place?
The Federalist Papers supported the passage of the U.S. Constitution. Name one of the writers.
What did the Declaration of Independence do?
We elect a U.S. Senator for how many years?
Name one branch or part of the government.
HOW WOULD YOU BE ABLE TO IDENTIFY streptococci THROUGH A MICROSCOPE
If the President can no longer serve, who becomes President?
What is the name of the President of the United States now?
What force is thought to be an important cause plate tectonic motion ?
Which change results in the formation of different substances? (1) burning of propane (2) melting of NaCl (s) (3) deposition of CO2(g) (4) solidification of wat