AQA A-Level Computer Science 7517
Fundamentals of Programming
Fundamentals of Data Structures
Fundamentals of Algorithms
Theory of Computation
Fundamentals of Data Representation
Fundamentals of Computer Systems
Fundamentals of Computer Organisation and Architecture
Fundamentals of Communication and Networking
Consequences of Uses of Computing
Systematic Approach to Problem Solving
Fundamentals of Databases
Big Data
Fundamentals of Programming
Boolean operations
- 1 thing to know
- Paper 1
Overview
Recall questions on the NOT, AND, OR and XOR operations, how XOR differs from OR, evaluating them for given values, and writing compound conditions with them.
What you need to know
Answer each one before you reveal it.
Questions from this subtopic
Each one with the model answer underneath.
- 1
What does the NOT operation do?
Model answer
It inverts a Boolean value: NOT True is False and NOT False is True. It is used to reverse a condition, for example WHILE NOT found.
- 2
What does the AND operation do?
Model answer
It gives True only when both of its operands are True, and False in every other case. It is used when two conditions must hold at once, for example age >= 13 AND age <= 19.
- 3
What does the OR operation do?
Model answer
It gives True when at least one of its operands is True, and False only when both are False. It is inclusive, so it is still True when both operands are True.
- 4
What does the XOR operation do, and how does it differ from OR?
Model answer
Exclusive OR gives True when exactly one of its operands is True, and False when they are both True or both False. It differs from OR only in the both-True case, which OR calls True and XOR calls False. XOR is the 'one or the other but not both' operator, and it has the useful property that applying the same value twice returns the original.
- 5
A is True and B is False. Evaluate NOT A, A AND B, A OR B and A XOR B.
Model answer
NOT A is False. A AND B is False, because B is not True. A OR B is True, because A is True. A XOR B is True, because exactly one of the two is True.
- 6
Both P and Q are True. Which of P AND Q, P OR Q and P XOR Q are True?
Model answer
P AND Q is True and P OR Q is True, but P XOR Q is False, because exclusive OR requires exactly one operand to be True and here both are.
Other ways to work this
The same content, four other ways.
What is inside Levo
Six ways to work the same material.
Every question in Fundamentals of Programming, on a schedule.
Attempt a question from memory, write the correct version, then attempt it again. Levo records the jump between your first attempt and your last, and brings each question back on the day you are due to forget it.
Or £46 a year, about £3.83 a month. Cancel anytime.