🐍 Paper 2 · Topic 6: Programming
6.6 Programming Project Guidance
Edexcel 1CP2 · GCSE Computer Science · ~12 min read · ✅ Free
Notes
──
Video
──
Slides
──
Worksheet
──
Quiz
🎉

Final Lesson — You're Nearly There!

This is the last lesson in Topic 6. After this, you'll have covered the complete Edexcel 1CP2 specification.

About Paper 2: On-Screen Practical

Paper 2 is a 1 hour 30 minute on-screen practical exam. You will write, test, and modify Python programs in a real IDE. The exam tests your ability to solve programming problems, not just knowledge of theory.

FeatureDetails
Duration1 hour 30 minutes
Marks60 marks
FormatOn-screen; write and run real Python code
LanguagePython 3
Resources allowedIDE only — no internet access

What the Exam Expects

Edexcel's Paper 2 tests all the skills from Topic 6. You need to be able to:

  • Write programs using variables, arithmetic, and string operations
  • Use selection (if/elif/else) to make decisions
  • Use iteration (for and while loops) for repetition
  • Define and call functions/procedures
  • Work with lists, tuples, and dictionaries
  • Read from and write to files
  • Write defensive code with try/except and validation loops
  • Trace and debug code with errors (syntax, runtime, logic)
  • Test using normal, boundary, and erroneous data

Edexcel Pseudocode → Python Reference

Paper 2 questions may use Edexcel pseudocode. Know these equivalents:

Edexcel pseudocodePython equivalent
INTEGER, REAL, STRING, BOOLEANint, float, str, bool
OUTPUT "text"print("text")
INPUT xx = input("prompt")
x ← valuex = value
IF condition THEN ... ENDIFif condition: ...
FOR i ← 1 TO 10 ... NEXT ifor i in range(1, 11): ...
WHILE condition DO ... ENDWHILEwhile condition: ...
PROCEDURE name() ... END PROCEDUREdef name(): ...
FUNCTION name() ... RETURN valuedef name(): ... return value
DIV (integer division)// in Python
MOD (remainder)% in Python
AND, OR, NOTand, or, not

Approaching Exam Questions

Follow this strategy for programming questions:

  • Read carefully — identify exactly what inputs, processes, and outputs are needed
  • Plan first — rough pseudocode or flowchart before typing
  • Build incrementally — get a basic version working, then add features
  • Test as you go — run the program with sample inputs to check it works
  • Handle errors — add try/except and validation where appropriate
  • Comment your code — helps examiners follow your logic

Example Exam-Style Program

# Grade calculator — typical Paper 2 style question def get_grade(score): """Return a grade letter based on score.""" if score >= 90: return "A*" elif score >= 80: return "A" elif score >= 70: return "B" elif score >= 60: return "C" else: return "U" def main(): scores = [] for i in range(5): # collect 5 scores while True: try: s = int(input(f"Score {i+1}: ")) if 0 <= s <= 100: scores.append(s) break else: print("Enter 0–100") except ValueError: print("Must be a number") average = sum(scores) / len(scores) print(f"Average: {average:.1f}") print(f"Grade: {get_grade(average)}") main()

Paper 2 Checklist

✅ Topic 6 Mastery Checklist

Variables, data types, type casting (int, float, str, bool)
Arithmetic operators (+, -, *, /, //, %, **)
Comparison and logical operators (==, !=, >, <, and, or, not)
Selection: if/elif/else with nested conditions
Iteration: for loops (range, lists), while loops, break/continue
Functions: parameters, return values, scope (global/local)
String operations: indexing, slicing, .split(), .join(), .upper(), .lower(), .find(), .replace(), len()
Lists: indexing, .append(), .insert(), .remove(), .sort(), 2D lists
Tuples and dictionaries: creation, access, iteration
File handling: open(), read/write/append modes, with statement
Defensive design: validation loops, try/except, error types
Testing: normal, boundary, erroneous data; test tables; error types
SDLC models: Waterfall, Iterative, Spiral — advantages and disadvantages
Pseudocode → Python translation (Edexcel keywords)
Final exam tip: In Paper 2, marks are awarded for logic — even if your code has a minor syntax error, you can still earn method marks. Always write logical, structured code with comments. If you're stuck, describe in comments what you would do — partial credit is possible. And always run your code before finishing!
Video coming soon
Click slide or press arrow keys to navigate
✍️

Worksheet — 6.6 Project Guidance

8 Edexcel-style questions · instantly marked

Q1State THREE features of Edexcel Paper 2 (e.g. duration, marks, format).[3]
✅ Mark scheme
Any three of: 1 hour 30 minutes [1]; 60 marks [1]; on-screen practical exam [1]; Python 3 [1]; no internet access — IDE only [1].
Q2Convert this Edexcel pseudocode to Python: FOR i ← 1 TO 5 OUTPUT i * 2 NEXT i[3]
✅ Mark scheme
for i in range(1, 6): [2] — range(1,6) gives 1 to 5 inclusive; print(i * 2) [1] — correct output statement. Note range(1,6) NOT range(1,5) which would only go to 4.
Q3Write a Python function that takes a list of numbers and returns the largest value without using max().[4]
✅ Mark scheme
def find_max(numbers): [1]; largest = numbers[0] or suitable initialisation [1]; for num in numbers: if num > largest: largest = num [1]; return largest [1]. Must define function, iterate correctly, compare correctly, return value.
Q4What does DIV and MOD mean in Edexcel pseudocode? Give the Python equivalent for each.[4]
✅ Mark scheme
DIV = integer (floor) division — divides and discards the remainder [1]; Python: // (e.g. 17 // 5 = 3) [1]; MOD = modulo — returns the remainder after division [1]; Python: % (e.g. 17 % 5 = 2) [1].
Q5Write Python code that reads names from a file "names.txt" and prints each one. Use the 'with' statement.[3]
✅ Mark scheme
with open("names.txt", "r") as f: [2]; for line in f: print(line.strip()) [1]. Accept: for line in f.readlines(): print(line.strip()). Award 1 mark for correct open with 'r' mode, 1 for 'with' statement, 1 for iterating and printing.
Q6Describe the strategy you would use to approach a Paper 2 programming question worth 8 marks.[4]
✅ Mark scheme
Any four of: read carefully to identify required inputs, processes, outputs [1]; plan with rough pseudocode or flowchart before coding [1]; build incrementally — get basic version working then add features [1]; test with sample inputs as you go [1]; add comments to explain logic [1]; add try/except and validation [1]; run the final code before submitting [1].
Q7Write a Python program that reads 10 integers from the user, stores them in a list, then prints the sum and average.[5]
✅ Mark scheme
nums = [] [1]; for loop 10 times [1]; int(input(...)) to get integer [1]; .append() to add to list [1]; print(sum(nums)) and print(sum(nums)/len(nums)) or equivalent average calculation [1]. Must store in list, not just accumulate total.
Q8A program has a logic error where it calculates area = length + width instead of length * width. How would this be detected, and what type of testing would catch it?[3]
✅ Mark scheme
Logic error — the program runs without crashing but gives wrong output [1]; detected by testing with known values and comparing actual vs expected output [1]; normal test data with known answers e.g. length=4, width=3 should give 12 but gives 7 [1]. Boundary/erroneous data would not specifically catch this — it requires testing with values where the correct answer is known.
Topic Quiz — Final Review
Q 1 of 15
You scored
out of 15
Click to reveal definition
🎉
Session complete!
TermDefinition
🎯

Mini Test — Final Topic 6 Review

Timed exam-style test — 10 minutes.

← 6.5 String Operations🎉 Final Lesson!Dashboard →