In a bank the account numbers are all 8 digit numbers, and
they all start with digit 2. So an account number can be represented as 2x

_{1}x_{2}x_{3}x_{4}x_{5}x_{6}x_{7}. An account number is considered to be a ‘magic’ number if x_{1}x_{2}x_{3}is exactly same as x_{4}x_{5}x_{6}or x_{5}x_{6}x_{7 }or both. x_{i}can take values from 0 to 9, but 2 followed by seven zeroes is not a valid account number. What is the maximum possible number of customers having a ‘magic’ account number?
Solution follows here:

__Solution:__
2x

_{1}x_{2}x_{3}x_{4}x_{5}x_{6}x_{7}
Considering the case “x

_{1}x_{2}x_{3}is exactly same as x_{4}x_{5}x_{6}”:
x

_{1}x_{2}x_{3}= x_{4}x_{5}x_{6}= 000, x_{7}=**1 to 9**as ‘20000000’ is not valid =>**9**possibilities
x

_{1}x_{2}x_{3}= x_{4}x_{5}x_{6 }= 001 to 999, x_{7}=**0 to 9**=> 999*10 =**9990**possibilities
Considering the case “x

_{1}x_{2}x_{3}is exactly same as x_{5}x_{6}x_{7}”:
x

_{1}x_{2}x_{3}= x_{5}x_{6}x_{7}= 000, x_{4}=**1 to 9**as ‘20000000’ is not valid => 9 possibilities
x

_{1}x_{2}x_{3}= x_{5}x_{6}x_{7 }= 001 to 999, x_{4}=**0 to 9**=> 999*10 =**9990**possibilities

__Subtracting common possibilities in both of the above cases:__

x

_{4}x_{5}x_{6}= x_{5}x_{6}x_{7 }=> x_{4}= x_{5}, x_{5}= x_{6}, x_{6}= x_{7}=> x_{4}= x_{5}= x_{6}= x_{7}
=> excepting all zero case, the possibilities are
1111,2222,...,9999 =>

**9**possibilities
These 9 cases are repeated in both of the above cases, hence
we need to subtract ‘9’ from the sum of no. Of possibilities of both the cases

=> Answer = 9 + 9990 + 9 + 9990 – 9 = 19989

**Answer (3)**
## No comments:

## Post a Comment