# The four digit number $AABB$ can be divided by $6$ without remainder. Determine the greatest and least value of $AABB$.

The four digit number $AABB$ can be divided by $6$ without remainder. Determine the greatest and least value of $AABB$.

On the condition that a number can be divided by $6$, it must be divisible by both $2$ and $3$

$$AABB \equiv 0 \pmod{2}\tag{1}$$ $$AABB \equiv 0 \pmod{3}\tag{2}$$

Reducing $AABB \equiv 0 \pmod{2}$,

$$AABB \equiv 0 \pmod{2} \implies 1000A + 100A + 10B + B \implies B \equiv 0 \pmod{2}$$

Now reducing $AABB \equiv 0 \pmod{3}$,

$$AABB \equiv 0 \pmod{3} \implies 1000A + 100A +10B + B \implies A + A + B + B \equiv 0 \pmod{3} \implies 2(A+B) \equiv 0 \pmod{3}$$

I think I've gone wrong so far.

• Should it be $B \equiv 0 \pmod 2$?
– xbh
Sep 2 '18 at 7:36
• @xbh Yes, it should. Sorry for that mistake. See the new edit.
– Busi
Sep 2 '18 at 7:37
• $AABB=11\times A0B$. Sep 2 '18 at 7:39
• It should be $2(A+B)\equiv0\pmod{3}$ You have $B\equiv0\pmod2$ That does not say that $\equiv0\pmod3$ Sep 2 '18 at 7:40
• @saulspatz How?
– Busi
Sep 2 '18 at 7:44

You have shown that we must have $B$ even and $A+B$ divisible by $3$. To make $AABB$ as large as possible, we'd like to have $A=9$ If this is so, can we find an even number $B$ such that $3|(9+B)?$ Similarly, to make $AABB$ as small as possible, we'd like to have $A=1$. What are the choices for $B?$
• Isnt it $3|2(9+B)$, which implies that $3|18+2B$?
• To the proposer: If $n\in \Bbb Z$ then $3|2n \iff 3|n.$ And $3|(9+B)\iff 3|B.$ So $3|2(9+b)\iff 3|(9+B)\iff 3|B.$ So if $A=9$ then $B\in \{0,3,6,9\}.$ But in this Q, $B$ must also be even. So if $A=9$ then $B\in \{0,3,6,9\}\cap \{0,2,4,6,8\}=\{0,6\}.$ Sep 2 '18 at 10:12
• @Busi If $3|2n$ then $3|n$. If $p$ is prime and $p|ab$ then $p|a$ or $p|b$. Since $3\nmid2$ it must be that $3|n$. Sep 2 '18 at 14:21