Computer Science 9608 · 10

Data types and structures

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

2017 October-November · Paper 21 · Q5(b)

Data types and records · 6 marks · official answer ready

(b) A function, IsEmailValid, is to be written to test for a valid email address format. An email address has a valid format if it obeys the following three rules: 1. It contains …

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

Data types and records · 6 marks · official answer ready

(i) Procedural high-level languages usually support different data types. Give an appropriate data type for each data value in the following table: Data value Data type FALSE 03/0…

2017 October-November · Paper 22 · Q2(a)

Data types and records · 2 marks

(a) Describe the purpose of the algorithm. ........................................................................................................................................…

2017 October-November · Paper 22 · Q3

Data types and records · 8 marks · official answer ready

3 A 1D array, Product, of type STRING is used to store information about a range of products in a shop. There are 100 elements in the array. Each element stores one data item. The…

2017 October-November · Paper 22 · Q5

Data types and records · 9 marks · official answer ready

5 A sports club maintains a record of the email address of each of its members. The details are stored in a text file, EmailDetails.txt. The format of each line of the text file i…

2017 October-November · Paper 23 · Q1(a)(i)

Data types and records · 6 marks · official answer ready

(i) Procedural high-level languages usually support different data types. Give an appropriate data type for each data value in the following table. Data value Data type 27 "27" "2…

2017 October-November · Paper 23 · Q3(a)

Data types and records · 8 marks · official answer ready

3 (a) A multi-user computer system stores information about users. It uses a 1D array, UserNameArray, of type STRING. There are 100 elements in the array. The format of the string…

2017 October-November · Paper 23 · Q5(b)

Data types and records · 6 marks · official answer ready

(b) A function, IsEmailValid, is to be written to test for a valid email address format. An email address has a valid format if it obeys the following three rules: 1. It contains …

2017 May-June · Paper 12 · Q4(b)(iii)

Files · 1 mark · official answer ready

(iii) The computer has recently been slow to load large files. The user has deleted a large number of small files to try to solve the problem. A friend has advised that there is a…

2017 May-June · Paper 21 · Q4(b)

Data types and records · 3 marks · official answer ready

(b) The following diagram shows part of a structure chart. Checkout B A C Card Account payment payment Examples of the data items that correspond to the arrows are given in this t…

2017 May-June · Paper 21 · Q6(b)(iii)

Data types and records · 2 marks · official answer ready

(iii) A program consisting of several modules may be tested using a process known as stub testing. Explain this process. ..........................................................…

2017 May-June · Paper 22 · Q3

Data types and records · 0 marks · official answer ready

3 READFILE (MyFile, String2)

2017 May-June · Paper 22 · Q6(b)

Data types and records · 5 marks · official answer ready

(b) The function is to be tested. Give a valid string that could be used to check that the function returns TRUE under the correct conditions. String1: ...........................…

2017 May-June · Paper 23 · Q4(b)

Data types and records · 3 marks · official answer ready

(b) The following diagram shows part of a structure chart. Checkout B A C Card Account payment payment Examples of the data items that correspond to the arrows are given in this t…

2017 May-June · Paper 23 · Q6(b)(iii)

Data types and records · 2 marks · official answer ready

(iii) A program consisting of several modules may be tested using a process known as stub testing. Explain this process. ..........................................................…

2017 May-June · Paper 31 · Q1(a)(i)

Data types and records · 1 mark · official answer ready

(i) Write a pseudocode statement to declare a variable, Book, of type LibraryBookRecord. ..........................................................................................…

2017 May-June · Paper 31 · Q1(a)(ii)

Data types and records · 1 mark · official answer ready

(ii) Write a pseudocode statement that assigns ‘Dune’ to the Title of Book. .......................................................................................................…

2017 May-June · Paper 32 · Q1(a)(i)

Data types and records · 1 mark · official answer ready

(i) Write a pseudocode statement to declare a variable, NewFriend, of type MyContactDetail. .......................................................................................…

2017 May-June · Paper 32 · Q1(a)(ii)

Data types and records · 1 mark · official answer ready

(ii) Write a pseudocode statement that assigns 129 to the HouseNumber of NewFriend. ...............................................................................................…

2017 May-June · Paper 32 · Q4(b)(i)

Files · 3 marks · official answer ready

(i) File A organisation ............................................................................................................. Justification ...............................…