If $A|B$ and $B|A$ then prove $A=\pm B$
So far I have $A|B \iff AX=B$ and $B|A \iff BY=A$ with $X,Y \in \mathbb{Z}$
Not sure how to finish, any help.
If $A|B$ and $B|A$ then prove $A=\pm B$
So far I have $A|B \iff AX=B$ and $B|A \iff BY=A$ with $X,Y \in \mathbb{Z}$
Not sure how to finish, any help.
You're almost there. Note that if you plug $A = BY$ into the first expression, you have
$$(BY)X = B.$$
Since we are discussing divisibility, $B\neq 0$ so we can divide both sides by $B$ to get
$$XY = 1.$$
What integers multiply together to give $1$?
You get that $AXY=A$, so unles $A=0$ we may conlcude that $XY=1$, whihc has only two solutions. If onthe other hand $A=0$ then the given considitions im ply $B=0$ anyway.
If $A|B$ then $B=AX$ as you said, but if $B|A$ we have as you write $A=BY$, substitute in our initial we get that $B=AX=BYX$, this can only be possible if $XY=1$, so we have two numbers times one another equals 1, which is $X=Y=1$ or $X=Y=-1$, hence it can be either of those.