Menu

Edexcel GCSE Computer Science (1CP2) Exam Questions

Build a practice paper from 604 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

3 questions · 11 marks

Pick again
Print
1Explain2 marksThe Internet Swap Remove

Every device that connects to the internet is given an IP address.

Explain one reason why every device on the internet needs a unique IP address.

[2 marks]
Mark scheme

Award up to two marks for a linked explanation such as:

  • Data/packets are delivered to the correct device (1) because the IP address identifies that device on the internet (1)
  • A reply is sent back to the device that made a request (1) because the sender's IP address is used as the destination address for the reply (1)
  • Routers can forward packets to the right device (1) because each packet's destination IP address matches only one device (1)
  • A device can be contacted by other devices (1) because other devices use its IP address to send data to it (1)

For both marks, the expansion must follow/associate with the statement.

Allow 'so the router knows where to send data' only when expanded to say the IP address identifies the destination device / is used by routers to forward the packet to that device.

Do not accept 'so it can connect to the internet' / 'so it can access the internet' without saying how the address is used to identify the device or deliver data to it.

Do not accept 'so the device can be identified' on its own without saying what the identification is used for, e.g. delivering data or returning a reply.

Do not award a mark for restating that an IP address is unique / every device has a different address.

Example answers and how they were marked
Full marks2/2

So that data reaches the correct device. The IP address is how the internet tells one device apart from another, so packets are sent to that device and not to a different one.

Why: Point (1): data reaches the correct device. Reason (1): the IP address identifies/tells devices apart, so packets are sent to that device.

Some marks1/2

So that packets go to the right device, because every device has a different address.

Why: Point (1): packets go to the right device. The reason only restates that every device has a different address, which the mark scheme says does not earn the second mark.

No marks0/2

So it can connect to the internet.

Why: No linked explanation of how the address is used; 'so it can connect to the internet' is not accepted without expansion.

2Calculate3 marksAdding Binary Numbers Swap Remove

Computers manipulate binary patterns.

(a)

Complete the table to show the 8-bit result of the binary addition.

[2 marks]
1286432168421
11000001
01100011
Mark scheme

Award one mark for each correct nibble in the correct order:

  • 0010 (1)
  • 0100 (1)

0 marks if the response is not 8-bit binary.

Ignore a carry shown beyond the eighth bit.

Example answers and how they were marked
Full marks2/2

0010 0100

Why: 193 + 99 = 292, which needs 9 bits; the 8 bits that are kept are both correct (2).

Some marks1/2

0010 0101

Why: A slip in the last bit. The first nibble is correct (1); the second is not.

No marks0/2

1110 0011

Why: Never carries. Neither nibble is correct.

(b)

State the name of the error that occurs when this addition is carried out.

[1 mark]
Mark scheme

Award one mark for:

  • overflow (error) (1)
Example answers and how they were marked
Full marks1/1

Overflow

Why: The result needs more bits than are available (1).

No marks0/1

Underflow

Why: A near miss: the result is too big for 8 bits, not too small.

No marks0/1

A syntax error

Why: A syntax error is a mistake in a program's code, not in arithmetic.

3Discuss6 marksTranslators Swap Remove

A company writes a photo editing program in a high-level language. The company will sell the finished program to customers. Each customer will install the program on their own computer and run it many times.

Discuss whether the company should use a compiler or an interpreter to translate the program before it is sold.

Your answer should include:

  • the output of each type of translator
  • whether the program has to be translated each time it is run
  • what the customer needs on their computer to run the program.
[6 marks]
Mark scheme

Indicative content

The output of each type of translator

  • A compiler translates the whole program in one go and produces object code.
  • The object code is saved as an executable file, which is already in machine code so the processor can run it directly.
  • An interpreter does not produce object code, so no translated file exists for the company to save and sell.
  • An interpreter translates one line at a time and executes it immediately, but that translation is not kept.

Whether the program has to be translated each time it is run

  • Compiled code is translated once, so the executable can be run as many times as the customer likes without being translated again.
  • If the source code is edited, the whole program has to be compiled again to produce a new executable.
  • An interpreted program is translated again every time it is run, so a customer who runs the program often waits for translation at every run.
  • An executable runs faster than interpreted code because it is already in machine code.

What the customer needs on their computer to run the program

  • A customer who installs the executable needs no compiler on their computer, so the program will run straight away.
  • If the company supplied the source code instead, the customer would need an interpreter installed, and it would have to be an interpreter for their type of computer.
  • A customer given only the executable does not have the source code, so cannot change the program.

Conclusion

  • A compiler is the better choice for this company, because the executable can be sold and the customer runs it without it being translated again and without being given the source code.
  • Using an interpreter would mean supplying the source code to customers and translating the program on every run.

Levels

  • Level 0 (0 marks): No rewardable content.
  • Level 1 (1–2 marks): Basic, independent points are made, showing elements of understanding of key concepts/principles of computer science. (AO1) The discussion will contain basic information with little linkage between points made or application to the context. (AO2)
  • Level 2 (3–4 marks): Demonstrates adequate understanding of key concepts/principles of computer science. (AO1) The discussion shows some linkages and lines of reasoning with some structure and application to the context. (AO2)
  • Level 3 (5–6 marks): Demonstrates comprehensive understanding of key concepts/principles of computer science to support the discussion being presented. (AO1) The discussion is well developed, with sustained lines of reasoning that are coherent and logically structured, and which clearly apply to the context. (AO2)

Level 3 responses must cover all three bullets for this company's program, including translating once rather than on every run, and reach a conclusion.

Do not accept 'a compiler fixes errors' (a compiler reports syntax errors at the end of translation, it does not fix them) or 'a compiler is easier to use' with no link to output, translation or the customer. Do not accept answers about translating to assembly language.

Example answers and how they were marked
Full marks6/6

The company should use a compiler. A compiler translates the whole program in one go and produces object code, which is saved as an executable file. This executable is already in machine code, so the customer's processor can run it directly. The program is translated only once, so a customer who runs the program many times does not wait for it to be translated again, and it runs faster than interpreted code would. An interpreter produces no object code, so the company would have nothing to sell as an executable. The customer would have to be given the source code and would need an interpreter installed on their computer, and the program would be translated again every time it was run.

Why: Level 3. Covers the output of both translators (executable from the compiler, no object code from the interpreter), the effect of translating once rather than on every run, and what the customer needs on their computer, all applied to the company selling the program, with a clear conclusion.

Some marks3/6

A compiler produces an executable file, which the company can save and sell to its customers. An interpreter does not produce an executable file, so the customer would need the source code and an interpreter installed on their computer to run the program. This means a compiler is better for the company, because customers can just run the file they are given.

Why: Level 2. Gives the output of both translators and links this to what the customer needs, with a conclusion, but never says the compiled program is translated once while an interpreted one is translated on every run, so the reasoning is not developed enough for Level 3.

No marks0/6

The company should use a compiler because it is easier to write programs with a compiler and it fixes the errors in the program before the customers get it.

Why: Level 0. No creditworthy point: 'easier to write programs' is not linked to the output, the translation each run or the customer, and 'fixes the errors' is a misconception, as the mark scheme's guidance says a compiler only reports errors at the end of translation.

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.