Programming
68 questions. Open a question to solve it and check the official answer.
Constructs · 9 marks
7 A company designs and sells furniture. Three different offices make up the company: Drawing Office - Staff use Computer Aided Design (CAD) software to design new furniture Finan…
Constructs · 1 mark · official answer ready
(a) A customer selects a lemon drink. Show how the code for this selection is stored in the 7-bit register: [1]
Constructs · 3 marks · official answer ready
(ii) The vending machine transmits eight codes (bytes), followed by a parity byte. The following bytes have been received by the computer: 1 0 0 0 1 0 1 1 1 0 0 0 1 1 0 1 0 0 1 1 …
Programming basics · 4 marks · official answer ready
(b) At the design stage, diagrams are used. Describe the function of the following diagrams in the design process. dataflow diagram (DFD) system flowchart [4]
Constructs · 2 marks · official answer ready
(iii) Explain what the computer system needs to do if more than 1 bit has been transmitted wrongly. [2] 10
Constructs · 3 marks · official answer ready
(a) The register for one particular lift contains the following values: In each case below, give the information being represented. lift number (in denary) current floor level (in…
Constructs · 3 marks · official answer ready
(b) State what the register for lift 17 would contain if it is currently on the 25th floor and is going up. [3] 13
Programming basics · 10 marks · official answer ready
(d) The function CheckAnswerCorrect gives the child three chances to type in the correct answer. The function returns TRUE if the child typed the correct answer, and FALSE if all …
Constructs · 9 marks
(a) Complete the pseudocode: FUNCTION TestScoreTotal RETURNS DECLARE AnswerCorrect, : BOOLEAN DECLARE , , : INTEGER // initialise Score Finish FALSE REPEAT Number1 // generate two…
Constructs · 5 marks · official answer ready
(i) A function, FindArrayIndex, is needed to return the array index of the record in which the child’s name is stored. Write pseudocode for this function. Assume: • the child’s na…
Constructs · 2 marks · official answer ready
(b) A child might type in their name with a mixture of upper and lower case letters and the program must allow for this. For example, ALI and Ali are treated as the same name. Des…
Programming basics · 10 marks · official answer ready
(d) The function CheckAnswerCorrect gives the child three chances to type in the correct answer. The function returns TRUE if the child typed the correct answer, and FALSE if all …
Constructs · 9 marks
(a) Complete the pseudocode: FUNCTION TestScoreTotal RETURNS DECLARE AnswerCorrect, : BOOLEAN DECLARE , , : INTEGER // initialise Score Finish FALSE REPEAT Number1 // generate two…
Constructs · 5 marks · official answer ready
(i) A function, FindArrayIndex, is needed to return the array index of the record in which the child’s name is stored. Write pseudocode for this function. Assume: • the child’s na…
Constructs · 2 marks · official answer ready
(b) A child might type in their name with a mixture of upper and lower case letters and the program must allow for this. For example, ALI and Ali are treated as the same name. Des…
Structured programming · 1 mark · official answer ready
(c) Sheena could have written the algorithm in part (a)(ii) as a procedure. What is the difference between a function and a procedure? [1] 4
Constructs · 8 marks
(d) Raul wants the user to be able to use an “undo” option to clear the previous entry if they think they have made an error. The “undo” option can be used repeatedly to return to…
Constructs · 20 marks · official answer ready
5 Raul copied the following pseudocode from a computing textbook. He wants to find out what it does. (i) Dry run the pseudocode using the trace table. FOR x 2 TO 4 ThisValue List[…
Constructs · 23 marks
5 7 8 6 5 1 9 2 4 3 7 9 5 4 9 3 2 5 7 4 6 1 8 4 1 6 4 1 7 8 6 3 9 5 2 7 1 6 3 2 4 7 8 9 1 6 5 1 4 6 3 1 7 9 4 5 6 8 2 3 5 8 1 6 5 8 3 2 1 7 9 4 1 4 9 7 8 3 6 1 5 2 4 9 2 7 1 5 9 6…
Constructs · 5 marks
5 7 8 6 5 1 9 2 4 3 7 9 5 4 9 3 2 5 7 4 6 1 8 4 1 6 4 1 7 8 6 3 9 5 2 7 1 6 3 2 4 7 8 9 1 6 5 1 4 6 3 1 7 9 4 5 6 8 2 3 5 8 1 6 5 8 3 2 1 7 9 4 1 4 9 7 8 3 6 1 5 2 4 9 2 7 1 5 9 6…
