carethegymnast1538 carethegymnast1538
  • 25-07-2020
  • Computers and Technology
contestada

What will be displayed if code corresponding to the following pseudocode is executed? Set Number = 4 Repeat Write 2 * Number Set Number = Number + 2 Until Number = 8

Respuesta :

thepingu
thepingu thepingu
  • 25-07-2020

Answer:

8

12

Explanation:

I made the code a bit easier to understand then worked out how it would go. Here's what I did.

number = 4

repeat until number = 8:

   write 2 * number

   number = number + 2

Following this itenary, we have, the system first writes "8" as it multipled 4 by 2. Number is now equal to 6.

Next repetition, the system writes "12" as it multipled 6 by 2. Now, number = 8. The proccess now stops as number is now equal to 8.

Answer Link

Otras preguntas

I need help with this
Gibbons v. Ogden reinforced __________. A. the Bill of Rights B. the states’ authority over the federal government C. the federal government’s authority over
Simplify the following expressions (x2y)(x5y3) (b3)6 (4x3)(2x)2 Hint: You need two different properties too solve this question.
1/23 to the thousandth power?
If f(x) = 3x, what is f(4)?
Which would most likely fall under the original jurisdiction if the Supreme Court
Which two ideas influenced key member of Russia's noble class while they were living abroad during the napoleonic wars
What is the major difference between a diagnosis of schizophrenia and schizophreniform disorder?
what is the measure of angle A in the triangle below? TIMED HELP
The distance between Lincoln, NE, and Boulder, CO, is about 500 miles. The distance between Boulder, CO, and a third city is 200 miles. Assuming the three citie