P(n)is the product of two digits in the integer n.For example, P(18)=1x8=18 ,P(99)=9x9=81.How to find the value of P(10)+P(11)+P(12)+..+P(99)?

1 Answer
Jul 15, 2018

The answer is 2025.

Explanation:

Based on how #P(n)# is defined, we can write the desired sum as

#P(10) + P(11)+P(12)+...+P(99)#

#=(1 xx 0) + (1 xx 1) + (1 xx 2) + ... + (9 xx 9)#

We can see that all these little products are pairing off the integers 1-9 with the integers 0-9, making all 90 pairs along the way.

What else pairs off every number from one set with every number from another set?

That's right—distribution!

You may remember distribution like this. When we have a product of two sums, you are taught to FOIL the product to find the answer, like this:

#(x + 3)(x+ 5) = x^2 + 5x + 3x + 15#
#color(white)((x + 3)(x+ 5)) = x^2 +"     " 8x "     "+ 15#

What you're really doing is pairing off each element of the first bracket #(x+3)# with each element from the other one #(x+5)#, making all 4 pairs along the way.

How does this help us?

It means, the sum of all these 90 products is a distributed form of a two-piece product. That is:

#(1 xx 0) + (1 xx 1) + (1 xx 2) + ... + (9 xx 9)#

#= (1 + 2 + 3 + ... + 9) xx (0 + 1 + 2 + ... + 9)#

This works because, if we were to redistribute the factored product above, we'd pair each number in #(1 + 2 + ... + 9)# with each number in #(0 + 1 + ... + 9)# and add all these products together, which is exactly the original sum we wanted.

This factored version is a lot easier to work with; we can just add all the numbers in each set of brackets, and then multiply the two sums.

#(1 + 2 + 3 + ... + 9) xx (0 + 1 + 2 + ... + 9)#

#=(45) xx (45)#

#=2025#

And there's our answer!