All papers

Computer Science · AQA 8525 · Paper 1: Computational thinking and programming skills · June 2022

AQA GCSE Computer Science Paper 1: Computational thinking and programming skills June 2022 question paper 8525/1

2h 90 marks

AQA 8525 · Paper 1

14 questions
Report a problem
What is wrong?

Goes to whoever maintains the question split. No account needed and nothing is published on this page.

Question 1

Figure for question 1

Shade one lozenge that shows the line number where selection is first used in the algorithm in Figure 1.

Question 1, shown as an image
Question 1, shown as an image
Question 1, shown as an image
Question 1, shown as an image

[1 mark]

Answer
Mark scheme for question 1.1

Shade one lozenge that shows the output from the algorithm in Figure 1 when the user input is 4

Question 1, shown as an image
Question 1, shown as an image
Question 1, shown as an image
Question 1, shown as an image

[1 mark]

Answer
Mark scheme for question 1.2

Shade one lozenge that shows the line number where assignment is first used in the algorithm in Figure 1.

Question 1, shown as an image
Question 1, shown as an image
Question 1, shown as an image
Question 1, shown as an image

[1 mark]

Answer
Mark scheme for question 1.3

Shade one lozenge that shows the line number that contains a relational operator in the algorithm in Figure 1.

Question 1, shown as an image
Question 1, shown as an image
Question 1, shown as an image
Question 1, shown as an image

[1 mark]

Answer
Mark scheme for question 1.4
Figure for question 1

[1 mark]

Answer
Mark scheme for question 1.5
Figure for question 1 Figure for question 1

[1 mark]

Answer
Mark scheme for question 1.6

Question 2

Figure for question 2
Figure for question 2

[2 marks]

Answer
Mark scheme for question 2.1

State how many possible values the result of the comparison deliveryDistance ≤ 5 could have in the algorithm shown in Figure 3.

[1 mark]

Answer
Mark scheme for question 2.2

State the most suitable data type for the following variables used in Figure 3.

Figure for question 2

[2 marks]

Answer
Mark scheme for question 2.3

State one other common data type that you have not given in your answer to Question 02.3.

[1 mark]

Answer
Mark scheme for question 2.4

Question 3

Figure for question 3

Rewrite line 5 in Figure 4 to concatenate the car registration with the string " is not valid", and store the result in the variable displayMessage.

Your answer must be written in C#.

[1 mark]

Answer
Mark scheme for question 3.1

The charge for parking for two or more hours is changed to include an additional £2 fee.

Rewrite line 15 in Figure 4 to show this change.

Your answer must be written in C#.

[1 mark]

Answer
Mark scheme for question 3.2

Question 4

The two C# programs in Figure 5 output the value that is equivalent to adding together the integers between 1 and an integer entered by the user.

For example, if the user entered the integer 5, both programs would output 15

Figure for question 4

Shade one lozenge to indicate which of the statements is true about the programs in Figure 5.

Question 4, shown as an image
Question 4, shown as an image
Question 4, shown as an image

[1 mark]

Answer
Mark scheme for question 4.1

Justify your answer for Question 04.1.

[2 marks]

Answer
Mark scheme for question 4.2

Question 5

Figure for question 5

The program shown in Figure 6 contains a syntax error.

Shade two lozenges to indicate the statements that are true about syntax errors.

Question 5, shown as an image
Question 5, shown as an image
Question 5, shown as an image
Question 5, shown as an image
Question 5, shown as an image

[2 marks]

Answer
Mark scheme for question 5.1

The program shown in Figure 6 also contains a logic error.

Identify the line number that contains the logic error, and correct this line of the program.

Your corrected line must be written in C#.

Question 5, shown as an image

Corrected line

[2 marks]

Answer
Mark scheme for question 5.2

What type of data structure is the variable numbers ?

[1 mark]

Answer
Mark scheme for question 5.3

Question 6

A program is being developed that allows users to rate and review movies. A user will enter their rating (out of 10) and a written review for each movie they have watched.

Computational thinking skills are used during the development of the program.

Define the term abstraction.

[1 mark]

Answer
Mark scheme for question 6.1
Figure for question 6 Figure for question 6 Figure for question 6

[2 marks]

Answer
Mark scheme for question 6.2

Question 7

Write a C# program to check if an email address has been entered correctly by a user.

Your program must:

• get the user to input an email address

• get the user to input the email address a second time

• output the message Match and output the email address if the email addresses entered are the same

maths symbol output the message Do not match if the email addresses entered are not the same.

You should use meaningful variable name(s) and C# syntax in your answer.

The answer grid below contains vertical lines to help you indent your code.

Figure for question 7

[5 marks]

Answer
Mark scheme for question 7

Question 8

Write a C# program that calculates the value of a bonus payment for an employee based on how many items they have sold and the number of years they have been employed.

The program should:

• get the user to input the number of items sold

• get the user to input the number of years employed

• output the value of the bonus payment: o if the years of employment is less than or equal to 2 and the number of items sold is greater than 100, then the bonus will be the number of items sold multiplied by 2 o if the years of employment is greater than 2, then the bonus will be the number of items sold multiplied by 10 o otherwise, the bonus is 0

You should use meaningful variable name(s) and C# syntax in your answer.

The answer grid below contains vertical lines to help you indent your code.

Figure for question 8

[7 marks]

Answer
Mark scheme for question 8

Question 9

Figure for question 9

Shade one lozenge which shows the output of line 4 from the algorithm shown in Figure 8.

Question 9, shown as an image
Question 9, shown as an image
Question 9, shown as an image
Question 9, shown as an image
Question 9, shown as an image

[1 mark]

Answer
Mark scheme for question 9.1

Shade one lozenge which shows the output of line 5 from the algorithm shown in Figure 8.

Question 9, shown as an image
Question 9, shown as an image
Question 9, shown as an image
Question 9, shown as an image
Question 9, shown as an image

[1 mark]

Answer
Mark scheme for question 9.2

State the output of line 7 from the algorithm shown in Figure 8.

[1 mark]

Answer
Mark scheme for question 9.3
Figure for question 9

[2 marks]

Answer
Mark scheme for question 9.4

Question 10

Figure for question 10

Complete the trace table for the subroutine call calculate(50)

You may not need to use all the rows in the table.

Figure for question 10

[4 marks]

Answer
Mark scheme for question 10.1

State the value that will be output for the subroutine call calculate(1)

[1 mark]

Answer
Mark scheme for question 10.2

The identifier for the variable b in Figure 9 was not a good choice.

State a better identifier for this variable that makes the algorithm easier to read and understand.

[1 mark]

Answer
Mark scheme for question 10.3
Figure for question 10 Figure for question 10

[2 marks]

Answer
Mark scheme for question 10.4

Question 11

Figure for question 11

[6 marks]

Answer
Mark scheme for question 11.1

A local variable called size has been used in getSize.

Explain what is meant by a local variable in a subroutine.

[1 mark]

Answer
Mark scheme for question 11.2

State three advantages of using subroutines.

[3 marks]

Answer
Mark scheme for question 11.3

Question 12

Figure for question 12

Complete the trace table for the algorithm shown in Figure 13.

Some values have already been entered. You may not need to use all the rows in the

Figure for question 12

[6 marks]

Answer
Mark scheme for question 12.1

State the purpose of the algorithm.

[1 mark]

Answer
Mark scheme for question 12.2
Figure for question 12

[1 mark]

Answer
Mark scheme for question 12.3

Question 13

A program is being developed in C# to simulate a card game.

Throughout the game each player always has 100 cards. Each card displays a number.

Players take it in turns to swap one of their cards with another random card from a set of cards until a player has a run of five numbers in sequence within their 100 cards.

Figure 14 shows part of the program that will get a player to enter the position of a card to swap.

Figure 14

Console.Write("Enter card position: "); int position = Convert.ToInt32(Console.ReadLine());

Extend the program in Figure 14. Your answer must be written in C#.

The program should keep getting the user to enter the card position until they enter a card position that is between 1 and 100 inclusive.

You should use meaningful variable name(s) and C# syntax in your answer.

The answer grid below contains vertical lines to help you indent your code.

Figure for question 13

[4 marks]

Answer
Mark scheme for question 13.1

There are 500 cards within the game in total. Each card is numbered from 1 to 250 and each number appears twice in the whole set of cards.

The player’s 100 cards are always stored in numerical order.

When a player has a valid run of five cards within their 100 cards they have won the game.

A valid run:

• consists of five cards

• can start from any position in the player’s 100 cards

• the second card’s value is one more than the first card’s value, the third card’s value is one more than the second card’s value, the fourth card’s value is one more than the third card’s value, and the fifth card’s value is one more than the fourth card’s value.

Below are examples of valid runs which means a player has won.

Valid run example 1

Figure for question 13

Valid run example 2

Figure for question 13

Below are examples of invalid runs.

Invalid run example 1

Figure for question 13

Invalid run example 2

Figure for question 13

Invalid run example 3

Figure for question 13

Write a C# program to check if a player has a valid run of five cards within their 100 cards.

When writing your program you should assume:

• there is an array called cards that contains the values of the player’s 100 cards

• cards[0] will contain the value of the first card and cards[99] will contain the value of the last card

• the values in cards are already stored in numerical order

• there is a Boolean variable called gameWon that has a value of False.

Your program should set gameWon to True if there is a valid run.

You should use meaningful variable name(s) and C# syntax in your answer.

The answer grid below contains vertical lines to help you indent your code.

Figure for question 13 Figure for question 13

[6 marks]

Answer
Mark scheme for question 13.2

Question 14

A program is being written to simulate a computer science revision game in the style of bingo.

At the beginning of the game a bingo ticket is generated with nine different key terms from computer science in a 3 x 3 grid. An example bingo ticket is provided in Figure 15.

Figure for question 14

The player will then be prompted to answer a series of questions.

If an answer matches a key term on the player’s bingo ticket, then the key term will be marked off automatically.

Figure for question 14

[4 marks]

Answer
Mark scheme for question 14.1
Figure for question 14

[8 marks]

Answer
Mark scheme for question 14.2

The paper as printed

June 2022 QP - Paper 1A AQA Computer Science GCSE

June 2022 QP - Paper 1B AQA Computer Science GCSE

June 2022 QP - Paper 1C AQA Computer Science GCSE

Spotted a mistake on this page?Report a problem