# Thread: Proof with divisibility and decimal representation

1. ## Proof with divisibility and decimal representation

I'm stuck on one of my homework problems:

Prove that if the decimal representation of a nonnegative integer n ends in d1d0 and if 4 | (10d1 + d0), then 4 | n.

It gave me a hint that if the decimal representation of a nonnegative integer n ends in d1d0, then there is an integer s such that n = 100s + 10d + d0

Also just wanted to check if this problem I did is correct:
For all integers a and b, if a|b then a|10 or a|b.
I used a counterexample of a=2 and b=3. Would that work?

One more thing, where or how can I make a source code out of my problems so they will be easier to read? Can't seem to find it in the editing tool or do I have to make them myself?

Thanks

2. To make clear, d1 and d0 are two digits (0 <= d1, d0 <= 9). Otherwise, it may seem that n ends with four decimal digits: d, 1, d, 0.

It gave me a hint that if the decimal representation of a nonnegative integer n ends in d1d0, then there is an integer s such that n = 100s + 10d1 + d0
Well, using this hint, suppose 4 | (10 * d1 + d0). Obviously, 4 | 100. Does it imply that 4 | n?

For all integers a and b, if a|b then a|10 or a|b.
Any implication of the form "If A, then B or A" is automatically true.

One more thing, where or how can I make a source code out of my problems so they will be easier to read?
There is a couple of LaTeX tutorials in the LaTeX forum.

3. i dont really understand this decimal representation. so does that mean d1 is 0 and d0 is 9? 4 | 100 and 4 | 100s where s is an integer.

4. d1 and d0 are two decimal digits. Each of them is one of 0, 1, 2, 3, 4, 5, 6, 7, 8, or 9. If a number n ends with two digits d1 and d0, this means that there exists an s such that n = 100*s + 10*d1 + d0. E.g., a number 123 ends in 2 and 3. This means that 123 = 100*1 + 10*2 +3.

Originally Posted by hellfire127
4 | 100 and 4 | 100s where s is an integer.
I am not sure if this is a question or a statement.