Problem:
What is the smallest integer larger than such that ends in the same three digits as does?
Problem:
What is the smallest integer larger than such that ends in the same three digits as does?
Solution:
The condition is that . Since , and cannot divide both and , must divide one of them. Similarly, must divide either or . We try successive values of that are congruent to or modulo and see which ones have the property that or is divisible by . It is easy to check that , and do not work, but the next value, , does, so this is the answer.