Question 2(a) 2021 · May-June · Paper 23 · 5 marks
Reveal official mark-scheme answer
Official answer for Question 2
Part (a)
Question 5
Question 1
Question 2
Question 3
Question 4
Question 5
Show text version of question
Question 2
Part (a)
Four program modules form part of a program for a library.
Module name Description
UpdateLoan() • Calls either LoanExtend() or LoanReturn()
- Called with parameters LoanID and BookID
- Calls CheckReserve() to see whether the book has been
- Returns TRUE if the loan has been extended, otherwise returns
- Called with BookID
- Called with parameters LoanID and BookID
LoanExtend() reserved for another library user
FALSE
CheckReserve() • Returns TRUE if the book has been reserved, otherwise returns FALSE
LoanReturn() • Returns a REAL (which is the value of the fine to be paid in the case of an overdue loan)
Draw a structure chart to show the relationship between the four modules and the parameters passed between them.
Question 5
Why this question appears here
82% assigned-topic match · Programming › Constructs
Topic-match percentages estimate how closely each question fits the selected syllabus topic. They are a guide for choosing stricter or broader practice.
Permanent source page: Educate A Change · From 9618_s21_qp_23.pdf
