x 10000 x \leq 10000

Algebra Level 3

Find the sum of all positive integers not greater than 10000 that are divisible by either 3 or 11 but not by both of them.


The answer is 18178182.

This section requires Javascript.
You are seeing this because something didn't load right. We suggest you, (a) try refreshing the page, (b) enabling javascript if it is disabled on your browser and, finally, (c) loading the non-javascript version of this page . We're sorry about the hassle.

1 solution

Marco Brezzi
Sep 10, 2017

Basically we have to sum all the multiples of 3 3 less than 10000 10000 with all the multiples of 11 11 less than 10000 10000 and subtract 2 2 times all the multiples of 33 33 less than 10000 10000 (which were added two times: one in the summation of the multiples of 3 3 and one in the summation of the multiples of 11 11 )

We first have to count how many multiples of 3 3 , 11 11 and 33 33 there are less than 10000 10000 , which are respectively

  • 10000 3 = 3333 \left\lfloor\dfrac{10000}{3}\right\rfloor=3333

  • 10000 11 = 909 \left\lfloor\dfrac{10000}{11}\right\rfloor=909

  • 10000 33 = 303 \left\lfloor\dfrac{10000}{33}\right\rfloor=303

Hence the required sum is

S = i = 1 3333 3 i + j = 1 909 11 j 2 k = 1 303 33 k = 3 i = 1 3333 i + 11 j = 1 909 j 66 k = 1 303 k = 3 3333 3334 2 + 11 909 910 2 66 303 304 2 = 18178182 \begin{aligned} S&=\displaystyle\sum_{i=1}^{3333}3i+\displaystyle\sum_{j=1}^{909}11j-2\displaystyle\sum_{k=1}^{303}33k\\ &=3\displaystyle\sum_{i=1}^{3333}i+11\displaystyle\sum_{j=1}^{909}j-66\displaystyle\sum_{k=1}^{303}k\\ &=3\cdot\dfrac{3333\cdot 3334}{2}+11\cdot\dfrac{909\cdot 910}{2}-66\cdot\dfrac{303\cdot 304}{2}\\ &=\boxed{18178182} \end{aligned}

0 pending reports

×

Problem Loading...

Note Loading...

Set Loading...