Computer Science 9608 · 11

Programming

471 questions. Open a question to solve it and check the official answer.

Reset
2017 October-November · Paper 12 · Q5(b)

Constructs · 4 marks · official answer ready

(b) Consider each incident you have identified as ethical behaviour. Draw a line from each incident to indicate the IEEE category it maps to. [4] 10

2017 October-November · Paper 13 · Q5(a)(i)

Programming basics · 3 marks · official answer ready

(i) Name three components of a speaker. 1 ........................................................................................................................................ …

2017 October-November · Paper 13 · Q7(e)

Constructs · 3 marks · official answer ready

(e) Write an SQL script to display the date and time of all appointments made by the patient with the PatientID of 556. ...........................................................…

2017 October-November · Paper 21 · Q1(c)

Constructs · 4 marks · official answer ready

(c) The following pseudocode is an example of nested IF statements. IF MyVar = 1 THEN CALL Proc1() ELSE IF MyVar = 2 THEN CALL Proc2() ELSE IF MyVar = 3 THEN CALL Proc3() ELSE OUT…

2017 October-November · Paper 22 · Q1(a)(iii)

Programming basics · 2 marks · official answer ready

(iii) An experienced programmer is presented with program code in an unfamiliar high-level language. State two features of the code that the programmer should be able to recognise…

2017 October-November · Paper 22 · Q1(d)(i)

Constructs · 2 marks · official answer ready

(i) Describe what will happen if the pseudocode is tested when MyMark has the following values: 27 ................................................................................…

2017 October-November · Paper 22 · Q1(d)(ii)

Constructs · 5 marks · official answer ready

(ii) Use pseudocode to write an IF statement with the same functionality. .........................................................................................................…

2017 October-November · Paper 22 · Q4

Structured programming · 0 marks

4 Programming languages provide built-in functions to generate random numbers. To be truly random, the frequency of each number generated should be the same. You are required to w…

2017 October-November · Paper 22 · Q10(c)

Programming basics · 11 marks

10 22 2 11 (c) The procedure is developed and run using the call TestRandom(200). No system errors are produced. To ensure that the procedure works correctly, you need to check th…

2017 October-November · Paper 23 · Q1(c)

Constructs · 4 marks · official answer ready

(c) The following pseudocode is an example of nested IF statements. IF MyVar = 1 THEN CALL Proc1() ELSE IF MyVar = 2 THEN CALL Proc2() ELSE IF MyVar = 3 THEN CALL Proc3() ELSE OUT…

2017 October-November · Paper 31 · Q3(b)

Programming basics · 6 marks · official answer ready

(b) Complete the Backus-Naur Form (BNF) for the syntax diagrams shown. has been done for you. ::= .................................................................................…

2017 October-November · Paper 31 · Q6(c)(iii)

Constructs · 3 marks · official answer ready

(iii) The code beginning at the instruction labelled HEATON must make the system turn on the heaters in those areas that are below the minimum temperature. Describe what this code…

2017 October-November · Paper 33 · Q3(b)

Programming basics · 6 marks · official answer ready

(b) Complete the Backus-Naur Form (BNF) for the syntax diagrams shown. has been done for you. ::= .................................................................................…

2017 October-November · Paper 33 · Q6(c)(iii)

Constructs · 3 marks · official answer ready

(iii) The code beginning at the instruction labelled HEATON must make the system turn on the heaters in those areas that are below the minimum temperature. Describe what this code…

2017 October-November · Paper 41 · Q1

Constructs · 7 marks · official answer ready

1 A greenhouse has a window that automatically opens and closes depending on the internal temperature. If the temperature rises above 20 °C, the window half opens. If the temperat…

2017 October-November · Paper 41 · Q4(a)

Constructs · 11 marks · official answer ready

(a) A program stores a letter. The user is allowed nine attempts to guess the stored letter. The program outputs “?” and the user guesses a letter. If the user guesses the letter,…

2017 October-November · Paper 41 · Q4(b)

Constructs · 0 marks · official answer ready

(b) Five numbers are stored, starting in the location labelled NUMBERS. A program is needed to multiply each of the numbers by 4 and store them back in their original location. Wr…

2017 October-November · Paper 42 · Q1(c)

Constructs · 3 marks · official answer ready

(c) Show how the columns from part (a) were simplified to create the columns in part (b). For example, if columns 5, 6 and 7 were simplified to create column X, then you state thi…

2017 October-November · Paper 43 · Q1

Constructs · 7 marks · official answer ready

1 A greenhouse has a window that automatically opens and closes depending on the internal temperature. If the temperature rises above 20 °C, the window half opens. If the temperat…

2017 October-November · Paper 43 · Q4(a)

Constructs · 11 marks · official answer ready

(a) A program stores a letter. The user is allowed nine attempts to guess the stored letter. The program outputs “?” and the user guesses a letter. If the user guesses the letter,…