Signed up recently but had issues with the confirmation email?

Click Forgot password and follow the reset steps. You can choose the same password you used when you signed up. This should then provide access.

Remember to check Spam and Junk. The email will be from auth@progressbytes.co.uk.

Revision notesQuestionsFor schools
Revise Computing
Log inStart revising free
Revision notesQuestionsFor schoolsLog in
GCSE Computer Science/Supplementary programming practice/Boolean Expressions

Translate logic

301.8 Boolean Expressions

Practise exam questions

Boolean Expressions — Note 3 of 3

Convert rules to Boolean.

What you need to know

Converting English rules into Boolean expressions is a key GCSE skill. Break the rule into parts, identify the comparisons, and connect them with and/or/not.

What to know

  • "Between 10 and 20" → x >= 10 and x <= 20
  • "Under 5 or over 65" → age < 5 or age > 65
  • "Not empty" → not name == "" or len(name) > 0
  • Write it in English first, then translate to code

Code examples

Translating rules
python
# Rule: "Pass if score is 50 or above AND attended > 80%"
score = 65
attendance = 85

if score >= 50 and attendance > 80:
    print("Pass")
← Previous noteLogical operators301.8 Boolean ExpressionsNext topic →IF and Else301.9 Selection

Back to Boolean Expressions

Specification notes for programming are in Paper 2.

Boolean Expressions

Note 3 of 3

  1. 1Comparison operators
  2. 2Logical operators
  3. 3Translate logic
Topic overview

© 2026 Revise Computing · revisecomputing.co.uk

Worried about something?Question Bank UpdatesPrivacy noticeTermsContact

Revise Computing is an independent revision resource. It is not affiliated with, or endorsed by, OCR (Oxford Cambridge and RSA Examinations).