Truth Table Examples in Math

Start with the recap, study the fully worked examples, then use the practice problems to check your understanding of Truth Table.

This page combines explanation, solved examples, and follow-up practice so you can move from recognition to confident problem-solving in Math.

Concept Recap

A table that systematically lists every possible combination of truth values for the input variables and the resulting truth value of the expression.

List every possible combination of T/F for inputs, and compute the output.

Read the full concept explanation →

How to Use These Examples

  • Read the first worked example with the solution open so the structure is clear.
  • Try the practice problems before revealing each solution.
  • Use the related concepts and background knowledge badges if you feel stuck.

What to Focus On

Core idea: A truth table enumerates all input truth assignments and the resulting value of an expression.

Common stuck point: The procedure for truth table is the easy part; the trap is listing fewer than 2n2^n rows. Asking "Am I listing every possible T/F combination of the inputs and the output for each?" first is what keeps a correct-looking calculation from being attached to the wrong concept.

Sense of Study hint: Ask: Am I listing every possible T/F combination of the inputs and the output for each?

Worked Examples

Example 1

easy
Construct the truth table for pqp \Rightarrow q.

Answer

pqpqTTTTFFFTTFFT\begin{array}{cc|c} p & q & p \Rightarrow q \\ \hline T & T & T \\ T & F & F \\ F & T & T \\ F & F & T \end{array}

First step

1
List all combinations: (T,T),(T,F),(F,T),(F,F)(T,T), (T,F), (F,T), (F,F).

Full solution

  1. 2
    Apply the rule: pqp \Rightarrow q is false only when pp is true and qq is false.
  2. 3
    Results: (T,T)T(T,T) \to T, (T,F)F(T,F) \to F, (F,T)T(F,T) \to T, (F,F)T(F,F) \to T.
A truth table systematically lists every possible combination of truth values for the variables and evaluates the compound statement for each.

Example 2

medium
Build a truth table to verify that pqp \Rightarrow q is logically equivalent to ¬pq\neg p \lor q.

Example 3

medium
Build the truth table for ¬pq\neg p \to q and identify in how many of the 4 rows it is true.

Example 4

medium
Use a truth table to determine whether ¬(pq)\neg(p \lor q) and ¬p¬q\neg p \land \neg q are equivalent.

Practice Problems

Try these problems on your own first, then open the solution to compare your method.

Example 1

medium
Construct the truth table for ¬(pq)\neg(p \land q) and verify it equals ¬p¬q\neg p \lor \neg q (De Morgan's Law).

Example 2

medium
Construct the truth table for p¬qp \land \neg q.

Example 3

easy
How many rows does a truth table for 2 variables P,QP, Q have?

Example 4

easy
How many rows does a truth table for 3 variables have?

Example 5

easy
In the row P=T,Q=TP = T, Q = T, what is the value of PQP \land Q (AND)?

Example 6

easy
In the row P=T,Q=FP = T, Q = F, what is the value of PQP \lor Q (OR)?

Example 7

easy
In the row P=TP = T, what is the value of ¬P\neg P (NOT)?

Example 8

easy
In the row P=F,Q=TP = F, Q = T, what is the value of PQP \to Q?

Example 9

easy
In the row P=T,Q=FP = T, Q = F, what is the value of PQP \to Q?

Example 10

easy
List all four input rows for two variables P,QP, Q in standard order.

Example 11

medium
Build the truth table column for PQP \land Q. In how many of the 4 rows is it true?

Example 12

medium
Build the truth table column for PQP \lor Q. In how many of the 4 rows is it true?

Example 13

medium
Construct the truth table for ¬PQ\neg P \lor Q and compare it to PQP \to Q.

Example 14

medium
In the truth table for P¬QP \land \neg Q, which single row makes it true?

Example 15

medium
Determine whether P¬PP \lor \neg P is a tautology using a truth table.

Example 16

medium
Determine whether P¬PP \land \neg P is a contradiction using a truth table.

Example 17

medium
For the expression (PQ)P(P \to Q) \land P, which row(s) make the whole expression true?

Example 18

challenge
Use a truth table to prove De Morgan's law ¬(PQ)¬P¬Q\neg(P \land Q) \equiv \neg P \lor \neg Q.

Example 19

challenge
Build the truth table for (PQ)(QR)(P \to Q) \land (Q \to R) with 3 variables, and identify in how many of the 8 rows it is true.

Example 20

challenge
Show, using a truth table, that PQP \to Q and its converse QPQ \to P are NOT logically equivalent.

Example 21

medium
In a truth table for PQP \oplus Q (exclusive or), which rows are true?

Example 22

medium
In a truth table for P(QR)P \to (Q \lor R), in the row P=T,Q=F,R=FP=T, Q=F, R=F, what is the value?

Example 23

easy
How many rows does a truth table for 4 variables p,q,r,sp, q, r, s have?

Example 24

easy
In the row p=F,q=Fp = F, q = F, what is the value of pqp \lor q?

Example 25

easy
In the row p=T,q=Tp = T, q = T, what is the value of pqp \leftrightarrow q (biconditional)?

Example 26

easy
In the row p=T,q=Fp = T, q = F, what is the value of pqp \leftrightarrow q?

Example 27

easy
How many rows does a truth table for n=5n = 5 variables have?

Example 28

medium
In how many of the 4 rows is the biconditional pqp \leftrightarrow q true?

Example 29

medium
Use a truth table to determine whether pqp \to q is logically equivalent to its contrapositive ¬q¬p\neg q \to \neg p.

Example 30

medium
Construct the truth table for (pq)¬p(p \lor q) \land \neg p. In which row(s) is it true?

Example 31

medium
Is p(pq)p \to (p \lor q) a tautology?

Example 32

medium
Is (pq)p(p \land q) \to p a tautology?

Example 33

medium
In the truth table for (pq)r(p \lor q) \to r with 3 variables, in row p=T,q=F,r=Fp=T, q=F, r=F, what is the value?

Example 34

medium
Determine whether (pq)(qp)(p \to q) \lor (q \to p) is a tautology.

Example 35

medium
In the truth table for p(qr)p \land (q \lor r) with 3 variables, in how many of the 8 rows is it true?

Example 36

medium
Build the truth table column for pqp \oplus q (exclusive or). In how many of the 4 rows is it true?

Example 37

hard
Use a truth table to determine whether p(qr)p \to (q \to r) is equivalent to (pq)r(p \land q) \to r.

Example 38

hard
In the truth table for (pq)(¬pq)(p \to q) \land (\neg p \to q) in 2 variables, in how many of the 4 rows is the expression true?

Example 39

hard
Use a truth table to determine whether ¬(pq)\neg(p \leftrightarrow q) is equivalent to pqp \oplus q.

Example 40

hard
Use a truth table to test whether the argument 'If pp then qq. Not qq. Therefore not pp.' is valid.

Example 41

hard
Build a truth table for (pq)(p¬q)(p \lor q) \land (p \lor \neg q) and simplify the result.

Example 42

hard
In the truth table for (pq)r(p \to q) \to r with 3 variables, in how many of the 8 rows is the expression true?

Example 43

challenge
Use a truth table to decide whether the argument 'If pp then qq. If qq then rr. Therefore if pp then rr.' is valid.

Example 44

challenge
Three Boolean variables p,q,rp, q, r. The output column is TT exactly when an odd number of inputs are TT. Build the truth table column and state the standard name of this function.

Related Concepts

Background Knowledge

These ideas may be useful before you work through the harder examples.

logical statement