Truth Tables

Suppose you are given two logical expressions, e.g., $p \to q$ and $\neg q \to \neg p$, and want to check if they are equivalent or not. You can do so by constructing the truth tables for each of the 2 expressions:

$p$$q$$\neg p$$\boldsymbol{\neg p \vee q}$
$0$$0$$1$$1$
$0$$1$$1$$1$
$1$$0$$0$$0$
$1$$1$$0$$1$
$p$$q$$p'$$q'$ $\boldsymbol{\neg \neg q \vee \neg p = q \vee \neg p}$
$0$$0$$1$$1$$1$
$0$$1$$1$$0$$1$
$1$$0$$0$$1$$0$
$1$$1$$0$$0$$1$

Because the sequences of truth values that we got under the $\neg p \vee q$ and $\neg \neg q \vee \neg p = q \vee \neg p$ columns are exactly the same: $\langle1, 1, 0, 1\rangle$, this means that the statement are equivalent, so $p \to q = \neg q \to \neg p$ is a valid equivalence!

The next 2 slides introduce additional such equivalence; we use $\Leftrightarrow$ to indicate that the two expressions are equivalent.