Category Archives: Pseudocode

2014 – Q18 (a)

An athlete is developing a mobile application (app).

The athletes will allow athletes to track weight in Kg.

Part of the pseudocode for the app is shown below.

2014 - q18 a

(i) Identify the line that contains a condition. (1)

(ii) Identify the line that stores a value in an array. (1)

(iii) Identify the line that accepts input values into the program. (1)

Answer

2014 – Q16 (b)

Jack has been asked to write a program to calculate the potential profit in a soft drinks business. The program will store the costs involved in producing and selling one litre of each drink.

The following calculations will be used to output the profit made for each litre of drink.

Manufacturing Cost = Water Cost + Flavouring Cost + Labour Cost

Profit = Selling Cost – Manufacturing Cost

Using pseudocode or a programming language of your choice, write a program to enter the required data, then calculate and display the profit for the soft drink business. (5)

2014 - Q16 b

 

Answer

2014 – Q14

Employees can only access their company network if they enter a correct username and password. A validation program is being developed and will run each time an employee logs on.

An extract of pseudocode from the program is shown below.

2014 - Q14

An error is noticed when the program is tested.

(a) Identify the line containing a logic error. (1)

(b) State how this error should be corrected. (1)

Answer