Our site uses cookies. Some of the cookies we use are essential for parts of the site to operate and have already been set. You may delete and block all cookies from this site, but parts of the site will not work. To find out more about cookies on this website, see our Cookie Policy
Accept
© eRevision.uk and ZigZag Education 2025
This test is run by .
Note that your final mark will not be saved in the system.

13. Computational Thinking Typeit

Target Level
C
Running Total
0
0%
Attempt
1 of 3

Type the correct answers into the spaces. Fill all the spaces before clicking ‘Check Answers!’

Type the output for each algorithm. If an output is Boolean, i.e. 'true' or 'false', write the output in full rather than writing '0' or '1'.



a = 5

b = 6

c = 4

if (a + b < b + c) then

    print(a + c)

else

    print(a + c * b)

endif

 

d = 5

if (d < 5)

    d = d + 2

else

    if (d > 5)

        d = d – 2

    endif

endif

print(d)

 


e = true

f = false

g = false

if (e OR f OR g) then

    f = true

elseif (!e OR !f OR !g)

    g = true

endif

print(g)

 

h = true

i = true

if ((h AND !i) OR (!h AND i)) then

    print(!h)

else

    print(!(!(h))

endif

 


 

j = 3

k = 6

m = 9

if (k * 3 == k + j) then

    m = m + m * m

else

    m = m + m + m

endif

print(m)

 

 

p = true

q = false

while (p == q)

    if (p == false)

        q = true

    endif

    p = !p

endwhile

print(q)


 

r = 5

t = true

u = 3

for v = u to r

    t = !t

next v

if (t) then

    print(r)

else

    print(u)

endif

 

w = true

x = false

y = 1

while (w != x)

    w = !w

    if y % 2 = 1

        x = !x

    endif

    y = y + 1

endwhile

print(y)

This is your 1st attempt! You get 3 marks for each one you get right. Good luck!

Pass Mark
69%