ExamBank Scot · N5 Computing Science question bank · All N5 Computing Science questions

N5 Computing Science 2021 Question 4

1 mark · Assignment, arithmetic and concatenation

A user enters the value 2 when running the program below. Line 1 DECLARE answer INITIALLY 0 Line 2 DECLARE numOne INITIALLY 3 Line 3 RECEIVE numTwo FROM KEYBOARD Line 4 SET answer TO numOne ^ numTwo Line 5 SEND answer TO DISPLAY State the output.

Marking scheme

9

Previous question: N5 Computing Science 2021 Question 3

Next question: N5 Computing Science 2021 Question 5