AQA GCSE Computer Science Paper 1 (1C), June 2025: Question 3

8 marks · Medium difficulty · Programming

Write a VB.NET program to calculate and output the total cost of a netball coaching session based on the number of students entered by the user.

Practise this question

Question

Question 03 asks students to write a VB.NET program that calculates the total cost of a netball coaching session for a group of students. The cost rules state: if there are more than 25 students, the booking fee is £100 with no other charges; otherwise, there is a booking fee of £20 plus £5 per student for 15 or fewer students, or £3 per student for more than 15 students. The program must get user input for the number of students and output the total cost, using meaningful variable names and VB.NET syntax. A blank ruled grid with indentation columns is provided for writing code.
Question text

03 Write a VB.NET program that calculates the total cost of a netball coaching session

for a group of students.

The total cost is calculated as follows:

• A booking fee of £20 plus:

o £5 per student if there are 15 students or fewer

o £3 per student if there are more than 15 students

• If there are more than 25 students, a booking fee of £100 and no other charges.

Your program should:

• get the user to enter the number of students

• output the total cost of the session.

You should use meaningful variable name(s) and VB.NET syntax in your answer.

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

[8 marks]

Mark scheme

Show the mark scheme Mark scheme for Question 03 allocating 8 marks: 2 marks for AO3 design (Mark A for meaningful variable names, Mark B for a selection construct based on number of students) and 6 marks for AO3 program logic (Mark C for input/storage, Mark D for one correct Boolean condition, Mark E for correctly checking all conditions, Mark F for one correct calculation expression, Mark G for all correct calculation expressions, Mark H for outputting the total). Sample code solutions in C#, Python, and VB.NET are provided.

Total

Question Part Marking guidance

marks

03 2 marks for AO3 (design) and 6 marks for AO3 (program) 8

Program Design

Note that AO3 (design) marks are for selecting appropriate techniques to

use to solve the problem, so should be credited whether the syntax of

programming language statements is correct or not and regardless of

whether the solution works.

Mark A for using meaningful variable names throughout;

Mark B for the use of a selection construct using the number of students;

Program Logic

Mark C for using user input and storing the result in a variable correctly for

the number of students;

Mark D for one correct Boolean condition to check number of students;

A. if the only error is quotes included around numeric values;

Mark E for correctly checking the number of students under all required

conditions; R. if any quotes included around numeric values;

Mark F for one expression that calculates total correctly, linked to the

condition for the intended pathway;

Mark G for expressions that calculate total correctly for each of the three

pathways;

Mark H for outputting only one total in an appropriate location that covers

all included pathways;

A. if 100 is output appropriately as part of a literal string under the correct

condition;

DPT use of £ sign in calculation or value assigned to variable

DPT for quotes around numbers

I. Case

I. Messages or no messages with input and output statements

I. Gaps/spaces throughout the code, except where to do so would explicitly

alter the logic of the code in a way that makes it incorrect.

Maximum 7 marks if any errors in code

Note to examiners

In C#/VB.NET examples, explicit variable declarations are not shown. Refer

to the specific language type issues section of the appropriate Marking

Guidance document. Any correct variable declarations in student answers

should be accepted.

C# Example 1 (fully correct)

All design marks are achieved (Marks A and B)

students = Convert.ToInt32(Console.ReadLine()); C

if (students > 25) { D

total = 100; F

}

else if (students > 15) { E

total = 20 + (3 * students); Part G

}

else {

total = 20 + (5 * students); Part G

}

Console.WriteLine(total); H

A. Write in place of WriteLine

I. missing Console.

Python Example 1 (fully correct)

All design marks are achieved (Marks A and B)

students = int(input()) C

if students > 25: D

total = 100 F

elif students > 15: E

total = 20 + (3 * students) Part G

else:

total = 20 + (5 * students) Part G

print(total) H

Python Example 2 (fully correct)

All design marks are achieved (Marks A and B)

students = int(input()) C

if students <= 15: D

print(20 + 5 * students) F

elif students > 15 and students <= 25: E

print(20 + 3 * students) Part G

else:

print(100) Part G

Python Example 3 (7 marks)

All design marks are achieved (Marks A and B)

No Mark E because > 25 is caught by students > 15 condition.

students = int(input()) C

if students <= 15: D

total = 20 + (5 * students) F

elif students > 15: Part E

total = 20 + (3 * students) Part G

elif students > 25: Part E

total = 100 Part G

print(total) H

VB.NET Example 1 (fully correct)

All design marks are achieved (Marks A and B)

students = Console.ReadLine() C

If students > 25 Then D

total = 100 F

ElseIf students > 15 Then Part E

total = 20 + (3 * students) Part G

Else Part E

total = 20 + (5 * students) Part G

End If

Console.WriteLine(total) H

A. Write in place of WriteLine

I. missing Console.

VB.NET Example 2 (7 Marks)

All design marks are achieved (Marks A and B)

No Mark E because > 25 is caught by students > 15 condition.

total = 0

students = Console.ReadLine() C

If students <= 15 Then D

total = 20 + (5 * students) F

ElseIf students > 15 Then Part E

total = 20 + (3 * students) Part G

ElseIf students > 25 Then Part E

total = 100 Part G

End If

Console.WriteLine(total) H

A. Write in place of WriteLine

I. missing Console.

How to answer it

Netball Coaching Cost Calculator (VB.NET)

📋 What this question tests

This 8-mark question evaluates both program design (AO3) and implementation logic (AO3) in VB.NET. You must demonstrate how to:

  • Read user input into an appropriately named variable.
  • Implement multi-way selection ( If...ElseIf...Else ) with correct relational operators.
  • Order conditional statements logically to prevent overlapping logic errors.
  • Perform arithmetic calculations based on different pricing rules.
  • Output the calculated result accurately once only.

Question 03 Breakdown & Full Mark Solution

8 Marks — VB.NET Programming Task

✅ Model Solution (Full 8 Marks)

Dim students As Integer Dim total As Integer students = Console.ReadLine() If students > 25 Then total = 100 ElseIf students > 15 Then total = 20 + (3 * students) Else total = 20 + (5 * students) End If Console.WriteLine(total)

Alternative: Checking students <= 15 first, followed by students <= 25 , and Else (or checking students > 15 And students <= 25 ) is also fully acceptable.

📐 Logic & Fee Breakdown

Students (n) Fee Rule Formula
n ≤ 15 £20 booking + £5/student 20 + (5 * students)
16 ≤ n ≤ 25 £20 booking + £3/student 20 + (3 * students)
n > 25 Flat rate £100 only 100

💡 Detailed Mark Scheme Breakdown

Mark Requirement How to Achieve
Mark A (Design) Meaningful variable names throughout Use identifiers like students , numStudents , and total , cost . Do not use single letters like x or y .
Mark B (Design) Selection construct using student count Use an If...Then structure that branches based on the student number variable.
Mark C (Logic) User input stored correctly students = Console.ReadLine() (explicit type conversion is credited, but not mandatory).
Mark D (Logic) At least one correct Boolean condition e.g., students > 25 or students <= 15 .
Mark E (Logic) All required conditions checked correctly All three tiers (≤ 15, 16–25, > 25) are accurately segregated without logic overlap.
Mark F (Logic) One calculation expression correct Correctly compute total for at least one branch (e.g., total = 100 or total = 20 + (3 * students) ).
Mark G (Logic) All three calculation expressions correct All three pathways correctly calculate or assign the cost.
Mark H (Logic) Output only one total for all pathways A single Console.WriteLine(total) placed after End If , or individual outputs inside each branch.

❌ Common Errors & Lost Marks

  • Condition Shadowing (Lost Mark E): If students <= 15 Then ... ElseIf students > 15 Then ' <-- ERROR! total = 20 + 3 * students ElseIf students > 25 Then total = 100 End If Any number over 25 (e.g. 30) is also greater than 15, so the code enters the second branch and never reaches the > 25 branch!
  • Including Currency Symbols: Writing total = £100 or total = "£" & 100 in the calculation logic results in a 1-mark deduction (DPT).
  • Quotes Around Numbers: Writing If students > "25" treats the value as a string instead of an integer.
  • Multiple / Redundant Outputs: Printing the total both inside each conditional branch and at the end causes multiple outputs.

🧠 Exam Technique & Syntax Tips

  • Top-Down Condition Ordering: When dealing with upper bounds, start with the strictest/highest value first ( > 25 ), then the next ( > 15 ), and finish with Else .
  • Combined Range Syntax: If starting low, remember that in VB.NET you must specify both sides:
    ElseIf students > 15 And students <= 25 Then .
  • VB.NET Syntax Quirks: Do not forget Then after If and ElseIf , and always close the block with End If .
  • Variable Declarations: While explicit declarations ( Dim ... As Integer ) are good practice, examiners award input marks even if Dim is omitted, provided the logic is sound.

Topics

3.2 Programming · 3.2.2 Programming concepts · 3.2.3 Arithmetic operations in a programming language · 3.2.4 Relational operations in a programming language · 3.2.7 Input/output

Question and mark scheme from the AQA GCSE Computer Science examination, Paper 1 (1C), June 2025. QuestionVault is an independent revision resource; questions remain the copyright of the awarding body.