goldy501 goldy501
  • 01-02-2021
  • Computers and Technology
contestada

What is the value of numC at the end of this loop?

numC = 12

while numC > 3:

numC = numC / 2


numC =

Respuesta :

fichoh
fichoh fichoh
  • 02-02-2021

Answer: 3

Explanation:

What is the value of numC at the end of this loop?

numC = 12

while numC > 3:

numC = numC / 2

numC =

The initial numC value = 12

Condition : while numC is greater than 3 ; 12 > 3 (condition met)

The expression numC / 2 is evaluated

numC / 2 = 12 / 2 = 6

numC then becomes 6 ;

Condition : while numC is greater than 3 ; 6 > 3 (condition met)

numC / 2 = 6 /2 = 3

numC = 3

Condition : while numC is greater than 3 ; 3 > 3 (condition not met)

Loop terminates

numC = 3

Answer Link

Otras preguntas

Please answer the question for me
Introduction: Sort the powers of the president into each category. formal powers serving as a ceremonial leader informal powers serving as head of a political p
pleaseeee Helppppp 55 Points Question Please Helppppppppp I begg everybody ​
Solve the problem then round your answer to the nearest tenth. 53.562 - 42.17 =
1, How to grow taller, I'm 16 currently 182cm, any personal experiences? 2. how tall will I be?
What were some human costs of the Vietnam War?
Which terrorist group has been a major force in the conflicts in iraq
Which type of galaxy are characterized by a lack of gas and dust in them and are populated by older stars? spiral elliptical peculiar irregular
Mathematical Skills for the Physical Sciences: Tutorial 40 of 43 Save & Exit Part A ? Question DIE & & 3 A car travels at a speed of 41 meters/secon
How can you calculate changes in thermal energy?