Theory Notes/💻 Topic 1: Solution Development/10.1.3
10.1.3Grade 10

Software Engineering Principles

Marks in Paper 1 are not only for output. Structure, naming, efficiency and readability all carry marks, and they're the difference between a pass and a distinction on a working program.

  • Meaningful identifiers: iTotalMarks, not x. CAPS memos accept Hungarian-style prefixes (iCount, rTotal, sName) but consistency matters more than the convention you pick.
  • One job per routine: a procedure that reads input AND calculates AND displays is doing three jobs.
  • No duplicated code: if you've copy-pasted, you probably wanted a procedure or a loop.
  • Comment the why, not the what: `// VAT is 15% from April 2018` is useful; `// add one to i` is not.
  • Indent consistently — two spaces per level is the Pascal convention.
PrinciplePoorBetter
Naminga := b * 0.15;vat := price * VAT_RATE;
EfficiencyLoop always runs to the endBreak out as soon as the item is found
Structure300 lines in one begin…endProcedures and functions, each doing one thing
Constantsif mark >= 50 then (twice)const PASS_MARK = 50;
Code efficiency
No unnecessary duplication — reuse a routine rather than copying it.
Execution efficiency
No unnecessary processing — stop a search the moment you find the answer.
Maintainability
How easily someone else (or you in six months) can change the program safely.

💡 Exam Tip

A PAT mark scheme allocates marks for exactly these things. Renaming your variables sensibly before submitting is one of the cheapest marks available.