Help me find a new solution for this logic problem If
$$ p\land q=p\land r $$
and
 $$p\lor q=p\lor r$$ 
then prove:
 $$r=q$$ 
So here’s how I’ve proved it already but there’s another way which I’m supposed to only use the Absorption law. My proof is in down below  but I’m looking for another way and without using the truth table
Add a $qv$ to both sides of the first equation:
$$qv(p \land q)=qv(p \land r)$$
$$q=(q \lor p)\land (q \lor r)$$ from the first equation :
$$q=(p \lor r) \land (q \lor r)$$
$$q=r \lor (p \land q)$$
$$q=r \lor (p \land r)=r$$
 A: Your proof is very hard to follow. Allow me to reconstruct:
We have:
$$p\land q=p\land r$$
Disjuncting $q$ to both sides, we get:
$$q\lor (p\land q)=q\lor (p\land r)$$
Thus:
$$q=(q \lor p)\land(q \lor r)$$
But given that:
$$p \lor q=p \lor r$$
we get:
$$q=(p \lor r)\land(q \lor r)$$
And so:
$$q=r \lor (p \land q) = r \lor (p \land r) = r$$
Well, that's basically correct, though I would say it really  needs to be clarified that:
$$q = q \lor (p \land q)$$
in order to go from:
$$q\lor (p\land q)=q\lor (p\land r)$$
to:
$$q=(q \lor p)\land(q \lor r)$$
In sum, you can do:
$$q \overset{Absorption}{=} q \lor (p \land q) \overset{p \land q = p \land r}{=} q \lor (p \land r) \overset{Distribution}{=} (q \lor p)\land(q \lor r) \overset{p \lor q=p \lor r}{=}$$
$$ (p \lor r)\land(q \lor r) \overset{Distribution}{=} r \lor (p \land q) \overset{p \land q = p \land r}{=} r \lor (p \land r) \overset{Absorption}{=} r  $$
Note that this demonstration uses Absorption twice, but it also uses Distribution ... (and also a Commutation to change $q \lor p$ to $p \lor q$). In fact, I highly doubt it you can do it with Absorption alone ... I think this is the proof that they were looking for.
A: For comparison, here's a somewhat automatic (but longer) proof based on conjunctive normal form (CNF):
\begin{align}
&\left((p \wedge q) \iff (p \wedge r)\right) \bigwedge \left((p \vee q) \iff (p \vee r)\right) \\
&\left((p \wedge q) \implies (p \wedge r)\right) \bigwedge \left((p \wedge r) \implies (p \wedge q)\right) \bigwedge \left((p \vee q) \implies (p \vee r)\right) \bigwedge \left((p \vee r) \implies (p \vee q) \right) \\
&\left(\neg(p \wedge q) \vee (p \wedge r)\right) \bigwedge \left(\neg(p \wedge r) \vee (p \wedge q)\right) \bigwedge \left(\neg(p \vee q) \vee (p \vee r)\right) \bigwedge \left(\neg(p \vee r) \vee (p \vee q) \right) \\
&\left((\neg p \vee \neg q) \vee (p \wedge r)\right) \bigwedge \left((\neg p \vee \neg r) \vee (p \wedge q)\right) \bigwedge \left((\neg p \wedge \neg q) \vee (p \vee r)\right) \bigwedge \left((\neg p \wedge \neg r) \vee (p \vee q) \right) \\
&\left((\neg p \vee \neg q \vee p) \wedge (\neg p \vee \neg q \vee r)\right) \bigwedge \left((\neg p \vee \neg r \vee p) \wedge (\neg p \vee \neg r \vee q)\right) \bigwedge \left((\neg p \vee p \vee r) \wedge (\neg q \vee p \vee r)\right) \bigwedge \left((\neg p \vee p \vee q) \wedge (\neg r \vee p \vee q) \right) \\
&\left(1 \wedge (\neg p \vee \neg q \vee r)\right) \bigwedge \left(1 \wedge (\neg p \vee \neg r \vee q)\right) \bigwedge \left(1 \wedge (\neg q \vee p \vee r)\right) \bigwedge \left(1 \wedge (\neg r \vee p \vee q) \right) \\
&\left(\neg p \vee \neg q \vee r)\right) \bigwedge \left(\neg p \vee \neg r \vee q\right) \bigwedge \left(\neg q \vee p \vee r\right) \bigwedge \left(\neg r \vee p \vee q \right) \quad \text{this is in CNF} \\
&\left(\neg p \vee \neg q \vee r)\right) \bigwedge \left(\neg q \vee p \vee r\right) \bigwedge \left(\neg p \vee \neg r \vee q\right) \bigwedge \left(\neg r \vee p \vee q \right) \quad \text{this is in CNF} \\
&\left((\neg p \vee p) \wedge (\neg q \vee r)\right) \bigwedge \left((\neg p \vee p) \wedge (\neg r \vee q)\right) \\
&\left(1 \wedge (\neg q \vee r)\right) \bigwedge \left(1 \wedge (\neg r \vee q)\right) \\
&\left(\neg q \vee r\right) \bigwedge \left(\neg r \vee q\right) \quad \text{this is in CNF} \\
&\left(q \implies r\right) \bigwedge \left(r \implies q\right) \\
&q \iff r
\end{align}
