August 30, 2010

Unlock the Safe



There is a safe with a 5 digit number as the key. The 4th
digit is 4 greater than the second digit, while the 3rd digit
is 3 less than the 2nd digit. The 1st digit is thrice the
last digit. There are 3 pairs in the number whose sum is 11.

Find the number.


8 comments:

  1. Since no one explained how they reached that combination, I think I should.

    First of all, I think the last sentence should be modified. In fact, saying "There are 3 pairs in the number whose sum is 11" means the number has a sum of 11 i.e. the sum of its digits is 11. IMHO saying "the number has 3 pairs whose sum is 11" would avoid confusion.

    Now for the solution.

    There are 5 digits, let's call them a,b,c,d,e

    The 4th digit is 4 greater than the second digit,

    d = b+4

    while the 3rd digit is 3 less than the 2nd digit.

    c = b-3

    The 1st digit is thrice the last digit.

    a = 3*e

    This means that there are only 2 variables, b and e, since all the others can be written in terms of b and e.

    b MUST be greater than or equal to 3, otherwise c will be negative

    b MUST be less than or equal to 5, otherwise d will be 10 or more (i.e. not a single digit)

    e is between 0 and 3. 4 or more would put a in the double digits.

    There are 10 possible pairs (Combination of 5-choose-2) of which 5 can never be 11;


    a+e = 3e+e = 4e can never be 11 if e is an integer

    b+c = 2b - 3 can't be more than 7

    b+d = 2b + 4 can't be 11 if b is an integer

    b+e can't be more than 8

    c+e = b+e-3 can't be more than 5

    Furthermore,

    a+ d can only be 11 if b=4 and e=1, and this makes it the onlt pair with a sum of 11.

    So we eliminate these 6 pairs, and we are left with 4 pairs, 3 of which must sum up to 11.

    The most obvious one is c + d because it only depends on b (c + d = b - 3 + b + 4 = 2b + 1)

    Solving for b we get b = 5

    the pair a + b = b + 3e
    solving a + b = 11 gives us e = 2

    with b = 5 and e = 2 the pair (d+e) will also sum up to 11 and thus we have our 3 pairs.

    a = 3e = 3*2 = 6
    b = 5
    c = b -3 = 2
    d = b +4 = 9
    e = 2

    ReplyDelete
  2. well explained.............

    ReplyDelete
  3. very well explained........... mr. whats ur email id .. i wanna add u

    ReplyDelete