Doubt in maths question / Arithmatic

quantity A: sum of all integers divisible by 3 from 1 to 200 inclusive.
quantity B: sum of all integers divisible by 5 from 1 to 250 inclusive.

My doubt: I understood that I would be required to find no. of multiples for each A and B case, which comes out to be 66 for A and 50 for B. However, why do multiply each of these quantities by the median, can’t we directly compare by just looking at the number of multiples?