Boolean Logic CS Thinking Example 2
Follow the full solution, then compare it with the other examples linked below.
Example 2
mediumComplete the truth table for A AND (NOT B) where A and B can each be TRUE or FALSE.
Solution
- 1 Step 1: When A=T, B=T: NOT B = F, T AND F = F.
- 2 Step 2: When A=T, B=F: NOT B = T, T AND T = T.
- 3 Step 3: When A=F, B=T: NOT B = F, F AND F = F. When A=F, B=F: NOT B = T, F AND T = F.
Answer
Results: (T,T)→F, (T,F)→T, (F,T)→F, (F,F)→F.
Truth tables systematically list all possible input combinations and their outputs. They are essential for understanding and verifying logical expressions.
About Boolean Logic
A system of logic that works with only two possible values—true and false—combined using the operators AND, OR, and NOT. Boolean logic provides the mathematical foundation for all decision-making in computing, from simple if-statements to complex database queries and digital circuit design.
Learn more about Boolean Logic →