# Example of commutative ring with two elements that don't generate entire ring

I believe that there should be an example of a commutative ring $R$ that contains two elements whose only common divisors are units but which do not generate the unit ideal.

$R$ can't be a Euclidean domain. I've been trying out some basic examples of non-integral domains, such as $\mathbb{Z}/4\mathbb{Z}$, but without luck so far.

Is there such an example?

• How about $\Bbb Z[X,Y]$? – Lord Shark the Unknown Aug 13 '18 at 6:41
• You won't be able to make this work if all ideals are principal. – Mark Bennet Aug 13 '18 at 7:25