Pseudocode practice quiz

Just learning to code? Is the language getting in your way? Give this pseudocode practice quiz a shot and see how well you think algorithmically.

What is output from the following code?

a = 2
loop while a < 10
   print a + " "
   a = a + 2
 
 
 
 
 

What is output from the following code?

x = 20
loop while x > 10
   x = x - 4
print x
 
 
 
 
 

What is output from the following code?

x = 10
loop while x > 85
   x = x - 5
print x
 
 
 
 
 

What is output from the following code?

x = 15
if x > 15 
   print "go"
if x < 20 
   print "stop"
 
 
 
 

What is output from the following code?

x = 10
sum = 0
loop while x > 3
   sum = sum + x
   x = x - 2
print sum
 
 
 
 
 

Question 1 of 5

[dwqa_post_comments]