Question 2(c) 2018 · October-November · Paper 43 · 8 marks
Reveal official mark-scheme answer

Official answer for Question 2
Part (c)
Question 1
mark per bullet point to max 8:
Question 8
Show text version of question
Question 2
Part (c)
Question 2
Kendra collects books. She is writing a program to store and analyse information about her books.
Her program stores information about each book as a record. The following table shows the information that will be stored about each book.
Field name Description Title The title of the book Author The first listed author of the book
ISBN for example: Fiction If the book is fiction (TRUE) or non-fiction (FALSE) LastRead The date when Kendra last read the book
Part (c)
The random access file, MyBooks.dat, stores the data about the books in the format:
<Title> <Author> <ISBN> <Fiction> <LastRead>
- prompts the user to input the ISBN of a book until the ISBN contains 13 numeric digits
- uses the function Hash() to calculate the disk address of the record
- reads the record for that book from MyBooks.dat into a variable of type Book
- outputs all the data about the book.
Use pseudocode to write the procedure FindBook().
You can assume that the record exists at the disk address generated.
...................................................................................................................................................
...................................................................................................................................................
...................................................................................................................................................
...................................................................................................................................................
...................................................................................................................................................
...................................................................................................................................................
...................................................................................................................................................
...................................................................................................................................................
...................................................................................................................................................
...................................................................................................................................................
...................................................................................................................................................
...................................................................................................................................................
...................................................................................................................................................
...................................................................................................................................................
...................................................................................................................................................
...................................................................................................................................................
...................................................................................................................................................
...................................................................................................................................................
...................................................................................................................................................
Question 7
...................................................................................................................................................
...................................................................................................................................................
...................................................................................................................................................
...................................................................................................................................................
...................................................................................................................................................
...................................................................................................................................................
...................................................................................................................................................
...................................................................................................................................................
...................................................................................................................................................
...................................................................................................................................................
...................................................................................................................................................
...................................................................................................................................................
...................................................................................................................................................
...................................................................................................................................................
...................................................................................................................................................
...............................................................................................................................................[8]
Question 8
Why this question appears here
82% assigned-topic match · Programming › Programming basics
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 9608_w18_qp_43.pdf
