How HKEAA Marks Python Questions

Understanding the marking scheme is half the battle. Many students lose marks not because they can't code, but because they don't know what examiners are looking for.

HKDSE ICT Python questions are marked using three categories of marks:

Follow-Through Marking: The Student's Safety Net

HKDSE uses "follow-through" (ft) marking. If you make an error in part (a), but your subsequent parts are correct given that error, you still get those marks.

Example: if part (a) asks you to calculate a total, and you write total = sum(scores) + 1 (wrong by 1), but part (b) correctly uses total, you only lose 1 mark โ€” not all the marks.

๐Ÿ’ก Strategy: Never leave a part blank. Even a partial attempt can earn follow-through marks in later parts.

Exact Output Matters

Output marks are awarded only for exact output. Common pitfalls:

Capitalisation

# Question asks for "Pass"
print("pass")   # โœ— WRONG โ€” loses mark
print("PASS")   # โœ— WRONG โ€” loses mark
print("Pass")   # โœ“ CORRECT

Spaces

# Question shows "Score: 85"
print("Score:",score)   # โœ— "Score: 85" (with space โ€” OK)
print("Score:"+str(score))  # โœ— "Score:85" (no space โ€” WRONG)
print(f"Score: {score}")  # โœ“ "Score: 85"

Decimal Points

# Question asks for 2 decimal places
print(87.5)          # โœ— Shows "87.5"
print(f"{x:.2f}")    # โœ“ Shows "87.50"

Common Ways Students Lose Marks

1. Indentation Errors

Python is indentation-sensitive. Inconsistent indentation causes syntax errors that lose all logic marks.

2. Missing Input Conversion

n = input("Enter a number: ")
total = n + 10   # โœ— TypeError โ€” input is string

n = int(input("Enter a number: "))
total = n + 10   # โœ“ Correct

3. Off-by-One Errors in range()

# To print 1 to 10
for i in range(1, 10):   # โœ— Prints 1 to 9
    print(i)

for i in range(1, 11):   # โœ“ Prints 1 to 10
    print(i)

4. Not Closing Files

Using open() without .close() can cost 1 mark. Use with instead:

with open('data.txt') as f:
    content = f.read()   # โœ“ Auto-closes

What Gets You the Full Marks

  1. Read the question twice before coding
  2. Copy variable names exactly as given in the question
  3. Match output format (spaces, capitalisation, decimals)
  4. Use meaningful variable names (shows good practice)
  5. Test your code by tracing through an example
  6. Attempt every part โ€” even partial credit adds up
๐ŸŽฏ Pro tip: When practising in PyForm, always run your code with the exact inputs from the question to verify output matches before moving on.

Practise Exam-Style Questions with Instant Feedback

PyForm's Special Task mode marks your Python answers HKDSE-style and shows you exactly what the examiner would write.

Start Practising Free โ†’