Menu

Edexcel GCSE Computer Science (1CP2) Exam Questions

Build a practice paper from 544 exam-style questions, each with its mark scheme and example answers. Print it, or answer it on paper and then open the mark schemes. Or browse the questions by topic.

Build a paper

Topics (none ticked: all of them)
Question types (none ticked: all of them)

Practice paper

1 question · 1 mark

Pick again
Print
1Multiple choice1 markTranslators Swap

A program contains a syntax error. An interpreter reports the error as soon as it finds it.

Identify when a compiler reports the syntax errors it finds in the source code.

[1 mark]
  • AAfter each line is translated
  • BAt the end of translating the program
  • CWhen the first error is found
  • DWhen the object code is run
Mark scheme
  • B At the end of translating the program (1)
  • The only correct answer is B. The correct answer is at the end of translating the program.
  • A is not correct because a compiler translates the whole program and does not report an error after each line; reporting after each line is how an interpreter behaves
  • C is not correct because a compiler does not stop at the first error; it finishes translating and reports the errors it finds at the end
  • D is not correct because syntax errors are found during translation, before the object code is run
Example answers and how they were marked
Full marks1/1

B At the end of translating the program

Why: Chosen option states that errors are reported once the whole program has been translated, as a compiler does (1).

No marks0/1

A After each line is translated

Why: Near miss: reporting an error after each line is the behaviour of an interpreter, not a compiler, so no mark.

No marks0/1

C When the first error is found

Why: Misconception that a compiler stops and reports at the first error it finds; a compiler reports the errors at the end of translation, so no mark.

Questions by topic

More ways to revise Edexcel GCSE Computer Science (1CP2)

Teachers: build a paper, print it with the mark schemes at the end, and sign your school up to set your classes activities on every topic.

Fetch Decode Explain isn't affiliated with or endorsed by Pearson Edexcel.