Question 3(e) 2016 · May-June · Paper 22 · 5 marks
Reveal official mark-scheme answer

Official answer for Question 3
Part (e)
Part (e)
Example VB.NET:
Max[5]
Question 22
- procedure heading and ending
- declaration of local variables
- assigning a file name
- open file for writing
- nested loop to access each array element
- write element out to file
- close file
Show text version of question
Question 3
Part (e)
Question 3
A crossword puzzle is based on a grid made up of white and black squares. The white squares are
to be filled with letters to form words across the grid and down the grid.
The crossword puzzle designer provides clues for each word. Words consist of at least 2 letters.
The square where a word starts, across or down, is numbered. The numbering starts at the top left of the grid and is consecutive, row by row.
Here is an example of a crossword grid:
1 2 3 4 5 6
7 8
9 10 11
12 13 14
Question 15
16 17
18 19
Part (e)
Zara wants to save the contents of the data structure Puzzle to a sequential file
Puzzle.TXT
Write program code for the procedure SavePuzzleToFile(Puzzle).
Programming language ............................................................................................................
Code .........................................................................................................................................
...................................................................................................................................................
...................................................................................................................................................
...................................................................................................................................................
...................................................................................................................................................
...................................................................................................................................................
...................................................................................................................................................
...................................................................................................................................................
...................................................................................................................................................
...................................................................................................................................................
...................................................................................................................................................
...................................................................................................................................................
..............................................................................................................................................
Question 15
Why this question appears here
82% assigned-topic match · Data types and structures › Files
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 9691_s16_qp_22.pdf
