zaarathelab wrote:An orderly has a number of pegs to peg in a row. At first he tried to peg 5 in each row, then 6, then 8 and then 12, but had always 1 left. On trying 13 he had none left. What is the smallest number of pegs that he could have had?
Let N be his number of pegs. From the first part of the problem it is clear that N is one more than a multiple of 5, 6, 8, 12. The smallest positive number that is a multiple of all of these numbers is, by definition, the least common multiple of 5, 6, 8, and 12. To find this, break the numbers down into their prime factors: 5, 2*3, 2*2*2, 2*2*3. From this we can deduce that the LCM is 2*2*2*3*5=120. Thus, the smallest non-trivial number of pegs he can have is 121. Other possible values of N can be obtained by adding 120 to this number. Mathematically, N=121+120n where n is a non-negative integer.
Now we have to find the smallest value of N such that N is divisible by 13. First, note that 121 divided by 13 is 9 remainder 4. That is, 121=13*9+4. Also, 120=13*9+3. So, every time we add 120 to 121, the remainder with respect to 13 will increase by 3: 4, 7, 10, 13. But having a remainder of 13 is the same as being divisible by 13, so we must have to add 120 three times before we get to a number that is divisible by 13. 121+3*120=
481