AP Computer Science Principles Flashcards: Boolean Expressions

Study Boolean Expressions in AP Computer Science Principles with focused flashcards that help you recognize the idea, recall the key rule, and apply it in practice-style prompts.

AP Computer Science Principles

Boolean Expressions

0 mastered0 still learning

0% Complete

QUESTION
1/ 80

What does the Boolean expression x OR yx \text{ OR } y evaluate if x=truex = true?

Tap card or press Space to flip

ANSWER

true. OR returns true when either operand is true.

How well did you know it?

Card 1 / 80

What this deck covers

This deck focuses on Boolean Expressions, giving you a quick way to review the definitions, rules, and examples that matter most for AP Computer Science Principles.

How to use these flashcards

Work through these flashcards in short sessions. Try to answer each prompt before flipping the card, then revisit any cards you miss until the explanation feels automatic.

All flashcards

Flashcard 1: What does the Boolean expression x OR yx \text{ OR } y evaluate if x=truex = true?

Answer: true. OR returns true when either operand is true.

Flashcard 2: What is the result of the Boolean expression: (NOT true) OR false(\text{NOT } true) \text{ OR } false?

Answer: false. Parentheses evaluate first: (NOT true)=false(\text{NOT } true) = false, then false OR false=falsefalse \text{ OR } false = false.

Flashcard 3: What is the result of the expression: NOT (false OR false)\text{NOT } (false \text{ OR } false)?

Answer: true. Parentheses evaluate first: (false OR false)=false(false \text{ OR } false) = false, then NOT false=true\text{NOT } false = true.

Flashcard 4: What is the result of the Boolean expression: NOT true\text{NOT } true?

Answer: false. NOT reverses the Boolean value.

Flashcard 5: What is the result of the Boolean expression: NOT (true AND true)\text{NOT } (true \text{ AND } true)?

Answer: false. Parentheses evaluate first: (true AND true)=true(true \text{ AND } true) = true, then NOT true=false\text{NOT } true = false.

Flashcard 6: What is the result of the expression: NOT (true OR false)\text{NOT } (true \text{ OR } false)?

Answer: false. Parentheses force OR first, then NOT: NOT true=false\text{NOT } true = false.

Flashcard 7: What does the expression x AND xx \text{ AND } x simplify to?

Answer: x. Idempotent law: a variable AND with itself equals itself.

Flashcard 8: Identify the result: NOT (false AND true)\text{NOT } (false \text{ AND } true)

Answer: true. Parentheses evaluate first: (false AND true)=false(false \text{ AND } true) = false, then NOT false=true\text{NOT } false = true.

Flashcard 9: What is the result of the expression: NOT (true OR false)\text{NOT } (true \text{ OR } false)?

Answer: false. Parentheses force OR first, then NOT: NOT true=false\text{NOT } true = false.

Flashcard 10: What is the result of the expression: true AND (NOT false)true \text{ AND } (\text{NOT } false)?

Answer: true. NOT false=true\text{NOT } false = true, then true AND true=truetrue \text{ AND } true = true.

Flashcard 11: Identify the result: NOT (false AND true)\text{NOT } (false \text{ AND } true)

Answer: true. Parentheses evaluate first: (false AND true)=false(false \text{ AND } true) = false, then NOT false=true\text{NOT } false = true.

Flashcard 12: What does the Boolean expression x AND yx \text{ AND } y evaluate if x=falsex = false?

Answer: false. AND returns false when either operand is false.

Flashcard 13: What does the expression x OR NOT xx \text{ OR } \text{NOT } x simplify to?

Answer: true. Complement law: a variable OR its negation always equals true.

Flashcard 14: What is the result of the expression: NOT (false OR true)\text{NOT } (false \text{ OR } true)?

Answer: false. Parentheses evaluate first: (false OR true)=true(false \text{ OR } true) = true, then NOT true=false\text{NOT } true = false.

Flashcard 15: State De Morgan's Law for NOT (A AND B).

Answer: NOT A OR NOT B. De Morgan's Law distributes NOT over AND.

Flashcard 16: Identify the result: false AND (true OR false)false \text{ AND } (true \text{ OR } false)

Answer: false. Parentheses evaluate first: (true OR false)=true(true \text{ OR } false) = true, then false AND true=falsefalse \text{ AND } true = false.

Flashcard 17: What is the result of the Boolean expression: true AND falsetrue \text{ AND } false?

Answer: false. AND requires both operands to be true.

Flashcard 18: State De Morgan's Law for NOT (A OR B).

Answer: NOT A AND NOT B. De Morgan's Law distributes NOT over OR.

Flashcard 19: Identify the result: false AND (true OR false)false \text{ AND } (true \text{ OR } false)

Answer: false. Parentheses evaluate first: (true OR false)=true(true \text{ OR } false) = true, then false AND true=falsefalse \text{ AND } true = false.

Flashcard 20: What is the result of the Boolean expression: NOT (true OR true)\text{NOT } (true \text{ OR } true)?

Answer: false. Parentheses evaluate first: (true OR true)=true(true \text{ OR } true) = true, then NOT true=false\text{NOT } true = false.

Flashcard 21: What is the result of the expression: (true AND false) OR false(true \text{ AND } false) \text{ OR } false?

Answer: false. Parentheses evaluate first: (true AND false)=false(true \text{ AND } false) = false, then false OR false=falsefalse \text{ OR } false = false.

Flashcard 22: What is the result of the Boolean expression: NOT (true OR true)\text{NOT } (true \text{ OR } true)?

Answer: false. Parentheses evaluate first: (true OR true)=true(true \text{ OR } true) = true, then NOT true=false\text{NOT } true = false.

Flashcard 23: What is the result of the Boolean expression: NOT (true AND true)\text{NOT } (true \text{ AND } true)?

Answer: false. Parentheses evaluate first: (true AND true)=true(true \text{ AND } true) = true, then NOT true=false\text{NOT } true = false.

Flashcard 24: What is the result of the Boolean expression: false OR falsefalse \text{ OR } false?

Answer: false. OR returns false only when both operands are false.

Flashcard 25: Which Boolean operation is performed first: AND or OR?

Answer: AND. AND has higher precedence than OR in Boolean operations.

Flashcard 26: What is the result of true OR (NOT true)true \text{ OR } (\text{NOT } true)?

Answer: true. NOT true=false\text{NOT } true = false, then true OR false=truetrue \text{ OR } false = true.

Flashcard 27: Which Boolean operator is associative: AND, OR, NOT?

Answer: AND, OR. Both AND and OR can group operands differently without changing result.

Flashcard 28: What is the result of the expression: NOT (true AND false)\text{NOT } (true \text{ AND } false)?

Answer: true. Parentheses evaluate first: (true AND false)=false(true \text{ AND } false) = false, then NOT false=true\text{NOT } false = true.

Flashcard 29: What is the precedence order of Boolean operators NOT, AND, OR?

Answer: NOT, AND, OR. NOT has highest precedence, then AND, then OR.

Flashcard 30: What is the result of the expression: true OR (false AND true)true \text{ OR } (false \text{ AND } true)?

Answer: true. Parentheses evaluate first: (false AND true)=false(false \text{ AND } true) = false, then true OR false=truetrue \text{ OR } false = true.

Flashcard 31: What is the result of the expression: NOT (false OR false)\text{NOT } (false \text{ OR } false)?

Answer: true. Parentheses evaluate first: (false OR false)=false(false \text{ OR } false) = false, then NOT false=true\text{NOT } false = true.

Flashcard 32: What is the result of the Boolean expression: true OR falsetrue \text{ OR } false?

Answer: true. OR returns true if at least one operand is true.

Flashcard 33: What is the result of the expression: NOT (false OR true)\text{NOT } (false \text{ OR } true)?

Answer: false. Parentheses evaluate first: (false OR true)=true(false \text{ OR } true) = true, then NOT true=false\text{NOT } true = false.

Flashcard 34: What is the result of the expression: true AND (NOT false)true \text{ AND } (\text{NOT } false)?

Answer: true. NOT false=true\text{NOT } false = true, then true AND true=truetrue \text{ AND } true = true.

Flashcard 35: What is the result of false OR (NOT false)false \text{ OR } (\text{NOT } false)?

Answer: true. NOT false=true\text{NOT } false = true, then false OR true=truefalse \text{ OR } true = true.

Flashcard 36: What is the identity element for the AND operation?

Answer: true. AND with true leaves the other operand unchanged.

Flashcard 37: State De Morgan's Law for NOT (A OR B).

Answer: NOT A AND NOT B. De Morgan's Law distributes NOT over OR.

Flashcard 38: What is the result of the Boolean expression: (NOT true) AND false(\text{NOT } true) \text{ AND } false?

Answer: false. Parentheses evaluate first: (NOT true)=false(\text{NOT } true) = false, then false AND false=falsefalse \text{ AND } false = false.

Flashcard 39: What is the result of the Boolean expression: NOT false\text{NOT } false?

Answer: true. NOT reverses the Boolean value.

Flashcard 40: What does the expression x AND xx \text{ AND } x simplify to?

Answer: x. Idempotent law: a variable AND with itself equals itself.

Flashcard 41: What is the result of false OR (NOT false)false \text{ OR } (\text{NOT } false)?

Answer: true. NOT false=true\text{NOT } false = true, then false OR true=truefalse \text{ OR } true = true.

Flashcard 42: Which Boolean operator is commutative: AND, OR, NOT?

Answer: AND, OR. Both AND and OR can switch operand order without changing result.

Flashcard 43: What is the result of the expression: true OR (false AND true)true \text{ OR } (false \text{ AND } true)?

Answer: true. Parentheses evaluate first: (false AND true)=false(false \text{ AND } true) = false, then true OR false=truetrue \text{ OR } false = true.

Flashcard 44: What is the identity element for the AND operation?

Answer: true. AND with true leaves the other operand unchanged.

Flashcard 45: What is the result of the expression: NOT (true AND false)\text{NOT } (true \text{ AND } false)?

Answer: true. Parentheses evaluate first: (true AND false)=false(true \text{ AND } false) = false, then NOT false=true\text{NOT } false = true.

Flashcard 46: What is the result of the Boolean expression: NOT false\text{NOT } false?

Answer: true. NOT reverses the Boolean value.

Flashcard 47: What is the result of the Boolean expression: NOT true\text{NOT } true?

Answer: false. NOT reverses the Boolean value.

Flashcard 48: Which Boolean operation is performed first: AND or OR?

Answer: AND. AND has higher precedence than OR in Boolean operations.

Flashcard 49: What does the expression x OR NOT xx \text{ OR } \text{NOT } x simplify to?

Answer: true. Complement law: a variable OR its negation always equals true.

Flashcard 50: Which Boolean operator is commutative: AND, OR, NOT?

Answer: AND, OR. Both AND and OR can switch operand order without changing result.

Flashcard 51: What is the result of the Boolean expression: true AND truetrue \text{ AND } true?

Answer: true. AND returns true only when both operands are true.

Flashcard 52: Which Boolean operator is associative: AND, OR, NOT?

Answer: AND, OR. Both AND and OR can group operands differently without changing result.

Flashcard 53: What is the result of the Boolean expression: true AND truetrue \text{ AND } true?

Answer: true. AND returns true only when both operands are true.

Flashcard 54: What is the result of the expression: (true AND false) OR false(true \text{ AND } false) \text{ OR } false?

Answer: false. Parentheses evaluate first: (true AND false)=false(true \text{ AND } false) = false, then false OR false=falsefalse \text{ OR } false = false.

Flashcard 55: What is the result of the Boolean expression: (NOT false) AND true(\text{NOT } false) \text{ AND } true?

Answer: true. Parentheses evaluate first: (NOT false)=true(\text{NOT } false) = true, then true AND true=truetrue \text{ AND } true = true.

Flashcard 56: What is the result of the expression: true AND false OR truetrue \text{ AND } false \text{ OR } true?

Answer: true. AND evaluates first: (true AND false) OR true=false OR true=true(true \text{ AND } false) \text{ OR } true = false \text{ OR } true = true.

Flashcard 57: What is the result of the expression: true AND false OR truetrue \text{ AND } false \text{ OR } true?

Answer: true. AND evaluates first: (true AND false) OR true=false OR true=true(true \text{ AND } false) \text{ OR } true = false \text{ OR } true = true.

Flashcard 58: What is the result of the Boolean expression: (NOT true) OR false(\text{NOT } true) \text{ OR } false?

Answer: false. Parentheses evaluate first: (NOT true)=false(\text{NOT } true) = false, then false OR false=falsefalse \text{ OR } false = false.

Flashcard 59: What does the Boolean expression x AND yx \text{ AND } y evaluate if x=falsex = false?

Answer: false. AND returns false when either operand is false.

Flashcard 60: What is the result of false AND (NOT true)false \text{ AND } (\text{NOT } true)?

Answer: false. NOT true=false\text{NOT } true = false, then false AND false=falsefalse \text{ AND } false = false.

Flashcard 61: What is the result of true OR (NOT true)true \text{ OR } (\text{NOT } true)?

Answer: true. NOT true=false\text{NOT } true = false, then true OR false=truetrue \text{ OR } false = true.

Flashcard 62: What does the expression x AND NOT xx \text{ AND } \text{NOT } x simplify to?

Answer: false. Complement law: a variable AND its negation always equals false.

Flashcard 63: What is the identity element for the OR operation?

Answer: false. OR with false leaves the other operand unchanged.

Flashcard 64: What does the Boolean expression x OR yx \text{ OR } y evaluate if x=truex = true?

Answer: true. OR returns true when either operand is true.

Flashcard 65: What is the result of the Boolean expression: NOT (NOT false)\text{NOT } (\text{NOT } false)?

Answer: false. Double negation: NOT (NOT false)=NOT true=false\text{NOT } (\text{NOT } false) = \text{NOT } true = false.

Flashcard 66: What is the result of the Boolean expression: true OR falsetrue \text{ OR } false?

Answer: true. OR returns true if at least one operand is true.

Flashcard 67: What is the result of false AND (NOT true)false \text{ AND } (\text{NOT } true)?

Answer: false. NOT true=false\text{NOT } true = false, then false AND false=falsefalse \text{ AND } false = false.

Flashcard 68: What is the result of the Boolean expression: true AND (NOT false)true \text{ AND } (\text{NOT } false)?

Answer: true. NOT false=true\text{NOT } false = true, then true AND true=truetrue \text{ AND } true = true.

Flashcard 69: State De Morgan's Law for NOT (A AND B).

Answer: NOT A OR NOT B. De Morgan's Law distributes NOT over AND.

Flashcard 70: What is the result of the Boolean expression: true AND (NOT false)true \text{ AND } (\text{NOT } false)?

Answer: true. NOT false=true\text{NOT } false = true, then true AND true=truetrue \text{ AND } true = true.

Flashcard 71: What is the identity element for the OR operation?

Answer: false. OR with false leaves the other operand unchanged.

Flashcard 72: What is the result of the Boolean expression: (NOT true) AND false(\text{NOT } true) \text{ AND } false?

Answer: false. Parentheses evaluate first: (NOT true)=false(\text{NOT } true) = false, then false AND false=falsefalse \text{ AND } false = false.

Flashcard 73: What does the expression x AND NOT xx \text{ AND } \text{NOT } x simplify to?

Answer: false. Complement law: a variable AND its negation always equals false.

Flashcard 74: What does the expression x OR xx \text{ OR } x simplify to?

Answer: x. Idempotent law: a variable OR with itself equals itself.

Flashcard 75: What is the result of the Boolean expression: false OR falsefalse \text{ OR } false?

Answer: false. OR returns false only when both operands are false.

Flashcard 76: What is the result of the Boolean expression: true AND falsetrue \text{ AND } false?

Answer: false. AND requires both operands to be true.

Flashcard 77: What is the result of the Boolean expression: NOT (NOT false)\text{NOT } (\text{NOT } false)?

Answer: false. Double negation: NOT (NOT false)=NOT true=false\text{NOT } (\text{NOT } false) = \text{NOT } true = false.

Flashcard 78: What does the expression x OR xx \text{ OR } x simplify to?

Answer: x. Idempotent law: a variable OR with itself equals itself.

Flashcard 79: What is the result of the Boolean expression: (NOT false) AND true(\text{NOT } false) \text{ AND } true?

Answer: true. Parentheses evaluate first: (NOT false)=true(\text{NOT } false) = true, then true AND true=truetrue \text{ AND } true = true.

Flashcard 80: What is the precedence order of Boolean operators NOT, AND, OR?

Answer: NOT, AND, OR. NOT has highest precedence, then AND, then OR.