23jrojas 23jrojas
  • 26-02-2021
  • Computers and Technology
contestada

What is output? c = 1 sum = 0 while (c < 10): c = c + 3 sum = sum + c print (sum)

Respuesta :

tonb
tonb tonb
  • 26-02-2021

Answer:

21

Explanation:

The values of c that make it into the loop are 1, 4, 7.

The values that are added to sum are 3 higher, i.e., 4,7 and 10.

The sum of those is 21.

p.s. why did you not run the program yourself?

Answer Link

Otras preguntas

Everyone (has/have) done his or her homework.
HELP) of the following WOULD YOU NOT FIND IN THE DESERT TORNADO DRY HUMIDITY HURRICANE NONE OF THE ABOVE
A fishing trawler sails from port P in the direction 024o for 30 km, and then in the direction 114o for 20 km. Calculate: a) the distance and bearing of the tra
What country first colonised Ghana​
How many carbon dioxide molecules react to form one glucose molecule during photosynthesis
Consider the following sequence -3; 2; 7; 12 Find an expression for the term Which term of the sequence with equal 77"}​
Sorry can someone help please…
why it is wrong to use the term 'Pure Air' in Science?
. In a replicating DNA molecule, the region in which parental strands are separating and new strands are being synthesized is called a(n)
A positive real number is 2 more than another. If the sum of the squares of the two numbers is 42, find the numbers.