Revision Library
Choose a subject
Menu
Computer Science
Need a new topic?
Missing a topic, found a bug, or want something added?

Book 2 of 4

A Level Computer Science Exam Papers Set B

AS Paper 4: Mixed Practice A, AS Paper 5: Mixed Practice B and AS Paper 6: Full AS Review

Level
A Level · AQA 7517 · OCR H446
Series
A Level Computer Science Exam Papers, book 2 of 4
Suitable for
Years 12-13, AQA / OCR
FreePDF download · 2027 edition · 72 A4 pages
  • One file, prints straight to A4
  • No account, no password

3 papers, mark schemes at the back. This set is one of 558 free PDFs on the shelf.

Pages
72 A4 pages
Papers
3 papers
Questions
74 · 260 marks
Answers
From page 54

What is inside

3 papers · answers from p54

Each paper starts with a page showing its marks and a suggested time, followed by the questions. The mark schemes for all 3 papers are at the back, so you can sit each paper as a mock and mark it afterwards.

  1. 01AS Paper 4: Mixed Practice A22 questions · 80 marksp3
  2. 02AS Paper 5: Mixed Practice B24 questions · 80 marksp19
  3. 03AS Paper 6: Full AS Review28 questions · 100 marksp35
  4. AnswersMark schemes for every paperp54

Each paper is drawn from one of our worksheet packs. Follow a paper title for the full pack on its own page, or browse every A Level Computer Science pack. Every book on the shelf is a complete printable workbook of up to 120 A4 pages.

Explore this volume

A Level Computer Science Exam Papers Set B includes AS Paper 4: Mixed Practice A (from page 3); AS Paper 5: Mixed Practice B (from page 19); AS Paper 6: Full AS Review (from page 35).

Worked question 2 - AS Paper 4: Mixed Practice A

A logic circuit implements the Boolean expression X = (NOT A) OR (B AND C).

Evaluate X when A = 1, B = 1 and C = 0, and state the general rule for when the OR operator gives an output of 1.

Answer

X = 0; OR gives 1 when at least one operand is 1 (including both).

Mark scheme

A1for X = 0
B1for OR producing 1 when at least one input is 1, including both

Question 19 - AS Paper 4: Mixed Practice A

4 marks

ASCII uses 7 bits to represent 128 characters, covering the basic English alphabet, digits and some punctuation and control characters. Unicode aims to represent characters from every writing system in the world, and is commonly encoded using UTF-8, a variable-length encoding using 1 to 4 bytes per character.

Explain one limitation of ASCII that Unicode addresses, and explain why UTF-8 is described as backward compatible with ASCII.

Answer

Unicode represents many more writing systems; ASCII codes retain identical one-byte UTF-8 values

Mark scheme

B1for ASCII having insufficient codes for many writing systems.
B1for Unicode assigning code points to a much wider set of characters.
B1for the ASCII code points 0 to 127 having identical single-byte values in UTF-8.
B1for explaining the compatibility consequence: ASCII-only text is valid UTF-8 with unchanged characters.

Question 18 - AS Paper 4: Mixed Practice A

4 marks

A processor without pipelining takes 4 clock cycles to fully process one instruction, and cannot start a new instruction until the previous one finishes.

A pipelined version of the same processor splits execution into 4 equal stages, so that once the pipeline is full, one instruction completes every clock cycle.

Calculate the number of clock cycles needed to fully process 10 instructions, without pipelining and with pipelining (assume the first instruction takes 4 cycles to complete, then one further instruction completes each following cycle).

State one hazard that can reduce the benefit of pipelining.

Answer

40 cycles without pipelining, 13 cycles with pipelining; a data or control hazard can reduce the benefit

Mark scheme

M1for 10 * 4 = 40 cycles without pipelining.
M1for using 4 + (10 - 1) to include pipeline fill and the remaining completions; accept an equivalent timing diagram.
A1for 13 cycles with pipelining.
B1for stating one valid pipeline hazard, such as a data hazard or a control hazard; no explanation is required.

Question 10 - AS Paper 4: Mixed Practice A

3 marks

A company is choosing between a processor with 1 core running at 4.0 GHz and a processor with 4 cores each running at 2.0 GHz, for a program that needs to process a large batch of independent image files. Assume comparable work per clock cycle, enough independent files to keep all cores busy, and negligible scheduling and I/O overheads.

State which processor is likely to complete the batch faster, and explain why, referring to the nature of the task.

Answer

Four-core 2.0 GHz processor; ideal aggregate throughput is twice that of the single 4.0 GHz core under the printed assumptions.

Mark scheme

B1for choosing the four-core 2.0 GHz processor under the printed assumptions.
B1for explaining that independent image files can be processed simultaneously on different cores.
B1for explaining that the extra parallel work outweighs the lower per-core clock speed; accept a qualitative comparison or 4 * 2.0 versus 1 * 4.0. A calculated ratio is not required.

Question 8 - AS Paper 5: Mixed Practice B

4 marks

The following pseudocode is executed on the list values = [-3, 8, -1, 5, -9, 2]:

count = 0

FOR EACH v IN values

IF v < 0 THEN

count = count + 1

ENDIF

NEXT v

OUTPUT count

Complete a trace showing which values cause count to increase, and state the value output.

Answer

Count increases at -3, -1 and -9; counts after each item: 1,1,2,2,3,3; output 3.

Mark scheme

M1for showing that -3 causes count to increase
M1for showing that -1 causes count to increase
M1for showing that -9 causes count to increase, with no other value identified as causing an increase
A1for output 3

Question 16 - AS Paper 5: Mixed Practice B

4 marks

Write pseudocode for a function called IsPalindrome that takes a string, s, as its parameter, and returns TRUE if s reads the same forwards and backwards, and FALSE otherwise. You may assume a function LEN(s) returns the length of s, and that individual characters of s can be accessed using s[i], indexed from 0.

Answer

FUNCTION IsPalindrome(s) left = 0 right = LEN(s) - 1 WHILE left < right IF s[left] != s[right] THEN RETURN FALSE ENDIF left = left + 1 right = right - 1 ENDWHILE RETURN TRUE ENDFUNCTION

Mark scheme

M1for IsPalindrome with parameter s
M1for comparing mirrored characters, or an equivalent comparison with the reversed string
A1for returning FALSE when any corresponding characters differ
A1for returning TRUE when all corresponding characters match; accept equivalent algorithms without requiring early return or a midpoint bound

Question 13 - AS Paper 5: Mixed Practice B

3 marks

A student writes the following pseudocode, intended to output the numbers 1 to 5:

i = 1

j = 1

WHILE i <= 5

OUTPUT i

j = j + 1

ENDWHILE

Explain why this code never terminates, and rewrite the loop body so it correctly outputs 1 to 5 and then stops.

Answer

i remains 1 because only j changes, so i <= 5 is always true and 1 is output repeatedly. Replace the loop body with OUTPUT i followed by i = i + 1.

Mark scheme

B1for explaining that only j changes, so i stays 1 and the guard i <= 5 never becomes false
M1for retaining OUTPUT i in the repaired loop body
A1for incrementing i by 1 after output, producing 1 to 5 and then stopping; removing j is optional

Question 16 - AS Paper 6: Full AS Review

4 marks

The following pseudocode is executed:

result = ''

FOR i = 1 TO 3

result = result + 'ab'

NEXT i

OUTPUT result

Complete a trace of the value of result after each iteration of the loop, and state the value output.

Answer

result: ab, abab, ababab; output ababab.

Mark scheme

M1for result = ab after the first iteration
M1for result = abab after the second iteration
A1for result = ababab after the third iteration
A1for output ababab

Question 11 - AS Paper 6: Full AS Review

3 marks

A student writes the following pseudocode, intended to output the numbers 1 to 5:

i = 1

j = 1

WHILE i <= 5

OUTPUT i

j = j + 1

ENDWHILE

Explain why this code never terminates, and rewrite the loop body so it correctly outputs 1 to 5 and then stops.

Answer

i remains 1 because only j changes, so i <= 5 is always true and 1 is output repeatedly. Replace the loop body with OUTPUT i followed by i = i + 1.

Mark scheme

B1for explaining that only j changes, so i stays 1 and the guard i <= 5 never becomes false
M1for retaining OUTPUT i in the repaired loop body
A1for incrementing i by 1 after output, producing 1 to 5 and then stopping; removing j is optional

A Level Computer Science Exam Papers runs to 4 volumes

Book 2 of 4 · 259 pages in the set

Each set is a separate free PDF with its own mark schemes at the back.

Volume 1

56 pp · 52 Qs

AS Paper 1: Data Representation and Logic, AS Paper 2: Networks and Systems and AS Paper 3: Algorithms and Structures

Volume 2 · this book

72 pp · 74 Qs

AS Paper 4: Mixed Practice A, AS Paper 5: Mixed Practice B and AS Paper 6: Full AS Review

Volume 3

59 pp · 48 Qs

A Level Paper 1: Algorithms and Data Structures, A Level Paper 2: Programming Theory and A Level Paper 3: Computer Systems

Volume 4

72 pp · 64 Qs

A Level Paper 4: Data and Networks, A Level Paper 5: Algorithms and Theory and A Level Paper 6: Systems and Theory Review

More A Level books

A Level Computer Science Topic Workbook 1

97 pp · 102 Qs

Structure and Function of the Processor, Types of Software and Development Methodologies, Exchanging Data: Databases, Networks and Web Technologies and 7 more