TITLE: Is it true that a ring has no zero divisors iff the right and left cancellation laws hold?
QUESTION [9 upvotes]: This is the definition of zero divisor in Hungerford's Algebra:

A zero divisor is an element of $R$ which is BOTH a left and a right zero divisor.

It follows a statement:
It is easy to verify that a ring $R$ has no zero divisors 
if and only if the right and left cancellation laws hold in $R$;
that is, 
for all $a,b,c\in R$ with $a\neq 0$, 
$$ab=ac~~~\text{ or }~~~ba=ca~~~\Rightarrow~~~ b=c.$$
I think it is not true.
But I can't find a counterexample.

REPLY [6 votes]: Lemma: A ring has a left (or right) zero-divisor if and only if it has a zero divisor.
Proof: Assume $ab=0$ for $a,b\neq 0$. 
If $ba=0$, you are done - $a$ is both a left and right zero divisor.
If $ba\neq 0$, then $a(ba)=(ab)a=0$ and $(ba)b=b(ab)=0$, so $ba$ is a left and right zero divisor.

Now it is much easier to prove your theorem.
If $ax=ay$ and $R$ has no zero-divisors, then $a(x-y)=0$. But, by the lemma, $R$ also has no left-zero divisors, so either $a=0$ or $x-y=0$.
Similarly for $xa=ya$.
On the other hand, if cancellation is true, then $a\cdot b=0=a\cdot 0$ means that either $a=0$ or $b=0$. So there can't be any left zero divisors, and thus no zero divisors.

REPLY [2 votes]: Suppose $ab = 0$ with $a, b \ne 0$.  Either $ba = 0$ (which means $a$ and $b$ are zero-divisors), or $ba \ne 0$, in which case $ba$ is a zero-divisor because $a(ba) = 0$ and $(ba)b = 0$.