dhakalkd1 dhakalkd1
  • 16-01-2020
  • Computers and Technology
contestada

write an algorithm to display the even number from 2 to 20
​

Respuesta :

problemsolver2019
problemsolver2019 problemsolver2019
  • 23-01-2020

Answer:

Step 1: START

Step 2: For I = 2 to 20

Step 3: if I %2 == 0

Step 4: PRINT I

Step 5: I= I + 2

Step 6: NEXT I

Step 7: STOP

Explanation:

The output of the above algorithm will be

2 4 6 8 10 12 14 16 18 20

Above, we are using the for loop, and it starts with I =2, and with every iteration I is incremented by 2. And hence, we get the above output.

Answer Link

Otras preguntas

which liquid will evaporate the fastest water salt water pepsi and gatorade?
Compare and contrast chinese and European means and motives for commercial expansion
find correct two decimal places, the radius of the circle with the given circumference: 35cm
The height of a meeting room that's measures 19 m by 12 m is 3 m. Glen plans to apply 2 coats of paint to the walls of the room. A 4 L can of paint covers about
Around the year 1000, Songhai’s leader converted to _____________________________, but most of the people continued to worship ________________________________.
Suppose Lynn rolls a fair die until a 6 appears on top. What is the probability that it rolls to get a six the first time?
59, 51, 55, 46, 50, 40, 44, ____, ____
Is two thirds the same as four sixths
What percent by mass of each chloroform molecule is composed of chlorine?
Work out 3\5 of 7? Working out will help too, thanks:)