SOLUTION: hello, I was wondering if anyone would know the chances that my SS#, home address and phone# all each add up to 42? I just recently noticed this and am wondering just how 3 random

Algebra ->  Complex Numbers Imaginary Numbers Solvers and Lesson -> SOLUTION: hello, I was wondering if anyone would know the chances that my SS#, home address and phone# all each add up to 42? I just recently noticed this and am wondering just how 3 random       Log On


   



Question 1150950: hello, I was wondering if anyone would know the chances that my SS#, home address and phone# all each add up to 42? I just recently noticed this and am wondering just how 3 random 9 and 10 digit numbers can all add up to the same #, considering they were randomly selected decades apart.

Answer by jim_thompson5910(35256) About Me  (Show Source):
You can put this solution on YOUR website!

This is an interesting question, but unfortunately it cannot be solved by hand in a reasonable timeframe. Thankfully computers are perfect for this sort of task. I wrote up a python script that generates all the integers from 100,000,000 to 999,999,999. For each number generated, I added up the digits and checked to see which added to 42. This took several hours even though I was using a fairly fast computer.

Below are the results I found:

  • There are 4,038,560 numbers between 100,000,000 and 199,999,999 that have their digits add to 42

  • There are 4,303,545 numbers between 200,000,000 and 299,999,999 that have their digits add to 42

  • There are 4,521,000 numbers between 300,000,000 and 399,999,999 that have their digits add to 42

  • There are 4,682,700 numbers between 400,000,000 and 499,999,999 that have their digits add to 42

  • There are 4,782,360 numbers between 500,000,000 and 599,999,999 that have their digits add to 42

  • There are 4,816,030 numbers between 600,000,000 and 699,999,999 that have their digits add to 42

  • There are 4,782,360 numbers between 700,000,000 and 799,999,999 that have their digits add to 42

  • There are 4,682,700 numbers between 800,000,000 and 899,999,999 that have their digits add to 42

  • There are 4,521,000 numbers between 900,000,000 and 999,999,999 that have their digits add to 42


The counts mentioned above sum to:
4,038,560+4,303,545+4,521,000+4,682,700+4,782,360+4,816,030+4,782,360+4,682,700+4,521,000 = 41,130,255

From 100,000,000 to 999,999,999 there are 41,130,255 different nine digit numbers such that we have their sum of their digits add to 42.

We'll use this value later, so let n = 41,130,255

-------------------------------------------------

If 'a' and b are integers such that b > a, then we can count how many integers are from 'a' to 'b' including both endpoints using this formula below
c = b-a+1

A small example: a = 3, b = 7
c = b-a+1
c = 7-3+1
c = 4+1
c = 5
We can verify this claim by noticing there are 5 items in the set {3,4,5,6,7}

Use that formula to quickly compute how many integers are between a = 100,000,000 and b = 999,999,999 inclusive of both endpoints
c = b-a+1
c = 999,999,999-100,000,000+1
c = 899,999,999+1
c = 900,000,000
So there are 900,000,000 integers spanning from 100,000,000 to 999,999,999.

This is the same as saying there are 900,000,000 nine digit numbers such that there arent any leading 0s in any of the strings. We can't have something like 012345678 as our nine digit number because of the 0 in front.

Divide the values of n and c
n/c = (41,130,255)/(900,000,000) = 0.045700283
This converts to 4.5700283%

We have a 4.57% chance of selecting a 9 digit number, which does not have leading zeros, that will have the digits add to 42. This probability is fairly small but not too much so. So its not that unlikely to have your situation occur with one string of digits.

With 2 strings of nine-digit numbers, there is a 0.045700283^2 = 0.002088515 = 0.2088515% chance of getting their digits to sum to 42

With 3 strings of nine digit numbers, there is a 0.045700283^3 = 0.000095445 = 0.0095445% chance of getting their digits to sum to 42.

The probability of 0.0095445% is really really small. Though that doesn't mean that your situation is impossible since we didn't get a probability of 0. I'd consider it a very strange and lucky coincidence that all three strings of digits summed to 42.

Note: I'm not considering 10 digit numbers because it took several hours to find all of the nine digit numbers mentioned in the counts above. It would take much longer, possibly a few days, to search through all of the 10 digit numbers and do the same thing (though with a super computer its probably much more feasible).