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 a Quotient and a remainder for this polynomial long division (2x²+20x+45)÷(x+7)Please hurry i need help i have a test and i dont know how to do it
Which of the following is a quality of a credible source? opinionated unique important reliable
How many minutes did he spend on homework in all?
how are political parties related to elections
All of the following sentences are simple EXCEPT A) Butterflies have large, often brightly-colored wings. B) Butterflies are most commonly preyed upon by bi
Accommodation of the eye refers to its ability to __________.
Which words in the sentence are the infinitive? Paul completed many of the repairs and had only a few tasks left to finish.
Restrictions placed on freedom during world war i
can somebody pls go answer my question i just asked If the sphere shown has a radius of 8 m, then what is the approximate volume of the sphere? Use 3.14 for pi
who gets to impeach federal officials