GCSE (9-1) Computer Science
Mark Scheme
J277/02: Unit 2.2 Programming Fundamentals
Question Answer Marks Guidance
1a 502 1
Must be exact. "50 2" (with space) is 0 marks.
1b The variables are Strings (text), so the + operator performs concatenation (joining) instead of addition. 1
Reject: "It just puts them together" (too vague). Must mention "String" or "Concatenation".
2
  • MOD: 2
  • DIV: 5
  • Power: 8
3
1 mark per correct value.
3
  1. CONST (or CONSTANT) (1)
  2. float (or Real, int) (1)
  3. str (or String) (1)
3
Case insensitive.
int is accepted for length, but float is better.
4a A named memory location (1) used to store data that can change while the program is running (1). 2
4b
  • Prevents accidental changes to the value.
  • Makes code easier to update (change value in one place only).
2
Reject: "It's faster". Focus on maintainability and safety.
5
  • Line 02: age = int(input("...")) (1) - Must show casting to integer.
  • Line 04: print(...) (Lower case 'p') (1) - Python is case-sensitive.
  • Line 04: ... + str(nextYear) (1) - Must cast integer back to string.
3
6a currentLevel is a Local variable. It only exists inside the function and cannot be accessed outside it. 2
Key term "Local variable" is required.
6b
  • Harder to debug (hard to track where the variable is changed).
  • Waste of memory (they stay in memory for the whole program duration).
2
7 Rows:
  • 3 | 3 | 3 (1)
  • 5 | 2 | 2 (1)
  • 6 | 1 | 1 (1)
  • Final Output: 6 (1)
  • Loop Stop: Loop correctly stops when x=1 (1)
5
8a
RECORD Player
    Nickname : String
    Score : Integer
    IsActive : Boolean
END RECORD
3
1 mark for RECORD keyword.
1 mark for correct field names.
1 mark for valid data types.
8b player1.Score = 500 1
Must use dot notation.
9a
if score > 80:
    print("Distinction")
elif score > 60:
    print("Merit")
else:
    print("Pass")
3
1 mark for correct elif.
1 mark for removing redundant check.
1 mark for else catch-all.
9b Once a condition is met, the processor skips the rest of the checks. The original code checked every IF statement regardless of the previous result. 2
10
  • CONST RATE = 1.25 (1)
  • gbp = float(input("...")) (1)
  • if gbp > 0: (1)
  • usd = gbp * RATE (1)
  • print(usd) (1)
  • else: print("Invalid") (1)
6