Boolean Logic Flashcards
(25 cards)
What is Boolean logic?
A form of algebra that uses true/false values to perform logical operations.
True or False: Boolean logic is used in computer programming.
True
What are the three basic operations in Boolean logic?
AND, OR, NOT
Fill in the blank: The AND operation returns true if ______.
both operands are true
What does the OR operation do?
It returns true if at least one operand is true.
True or False: The NOT operation inverts the truth value of its operand.
True
What symbol is commonly used to represent the AND operation?
∧ (or && in programming)
What symbol represents the OR operation?
∨ (or || in programming)
In Boolean logic, what is the result of TRUE AND FALSE?
FALSE
In Boolean logic, what is the result of TRUE OR FALSE?
TRUE
What is the truth table for the AND operation?
TRUE AND TRUE = TRUE, TRUE AND FALSE = FALSE, FALSE AND TRUE = FALSE, FALSE AND FALSE = FALSE
What is the truth table for the OR operation?
TRUE OR TRUE = TRUE, TRUE OR FALSE = TRUE, FALSE OR TRUE = TRUE, FALSE OR FALSE = FALSE
What is the truth table for the NOT operation?
NOT TRUE = FALSE, NOT FALSE = TRUE
What is a Boolean variable?
A variable that can hold one of two values: true or false.
Fill in the blank: In programming, conditional statements often use ______ logic.
Boolean
True or False: A combination of Boolean operations can create complex conditions.
True
What is a common use of Boolean logic in everyday technology?
Search engines use Boolean logic to refine search results.
What is the result of NOT (TRUE AND FALSE)?
TRUE
What does the expression (A OR B) AND C evaluate to if A is TRUE, B is FALSE, and C is TRUE?
TRUE
What is the purpose of parentheses in Boolean expressions?
To define the order of operations.
What is a logical circuit?
A physical representation of Boolean logic using electronic components.
Fill in the blank: The output of a logic gate is ______ based on its input values.
determined
True or False: XOR (exclusive OR) returns true if both operands are true.
False
What does XOR return when both operands are different?
TRUE