# Wish I had known this in 2012

Let $A$ be an integral domain, $I,J\subseteq A$ ideals such that $I+J=A$. If $I\cap J$ is principal, then $I$ and $J$ are projective.

1. The sequence $0\rightarrow I\cap J \rightarrow I\oplus J\rightarrow A\rightarrow 0$, where the last arrow is $(i,j)\mapsto i-j$, is exact by hypothesis. Now $I\cap J$ is principal and therefore isomorphic to $A$, since $A$ is a domain, and the sequence splits, since the rightmost term is projective. Then $I\bigoplus J\simeq A\bigoplus A$ and so both ideals are projective.
2. Consider the canonical exact sequence involving $I\cap J,I\oplus J$ and $I+J$.