Skip to main content
A-LevelComputer ScienceSystem software9618/31 · Oct/Nov 2021 · Q47 Marks

The following syntax diagrams for a particular programming language show the syntax of: • a digit • a capital letter • a character. [Figure 4.1]

  1. (a)Write the Backus-Naur Form (BNF) notation of the syntax diagram for character.[2]
  2. (b)(i)A password must begin with a character and be followed by one or more digits or capital letters. State an example of a valid password.[1]
  3. (b)(ii)A valid password is represented by the syntax diagram: [Figure 4.2] Write the BNF notation of the syntax diagram for password.[4]

This question uses a diagram from the original paper, which isn't shown here. Open the full paper from the past papers archive to see it.

Mark scheme

Marking points from the official mark scheme (Oct/Nov 2021). The mark or mark type is shown in brackets.

  1. [2] One mark for each marking point (Max 2)
  2. • <character>::=
  3. • $ | % | & | * | #
  4. Complete answer
  5. <character>::= $ | % | & | * | #
  6. [1] For example: $A9E3
  7. [4] One mark for each marking point (Max 4)
  8. • <password>::=<character> ...
  9. • ... <code>
  10. • <code>::= ...
  11. • ... <digit>|<capital_letter>
  12. • ... |<digit><code>|<capital_letter><code>
  13. Complete answer
  14. <password>::=<character><code>
  15. <code>::=<digit>|<capital_letter>|<digit><code>|<capital_letter><code>

Write your answer and get it marked

On Oracle Prep you can write or photograph your own answer and have it marked by AI against this mark scheme, with feedback on what you missed.

Sign up free →

About this question

Topic
System software, A-Level Computer Science (syllabus 9618). Structured question, 7 marks.
Source
A-Level Computer Science, Oct/Nov 2021 Paper 3 Variant 1, question 4.

Questions and mark schemes are from past examination papers and remain the copyright of the exam board. How Oracle Prep builds its content

Related Computer Science questions

© 2026 Oracle Prep