TCS
Company
Numerical Ability
Number System
Summation from i=0 to 6409 of ai = ?
where ai= 29(if ai is divided by 13 & 17)
ai= 17(if ai is divided by 13 & 29)
ai= 13(if ai is divided by 17 & 29)
ai=0 (else)
Read Solution (Total 5)
-
- here 13*17*29 = 6409 i.e 6409 is divisible by 13,17,29
i think, value of i should less than 6409 or a6409=0
no. of no.s divided by 17 & 29 = 6409/17*29 = 13 => 12 no.s
similarly,6409/13*29=17 => 16 no.s
and 6409/13*17=29 => 28 no.s
Sum= 12*13+16*17+28*29 = 1240 - 10 years agoHelpfull: Yes(28) No(1)
- 17*29=493 and 6409/493=13
29*13=377 and 6409/377=17
13*17=221 and 6409/221=29
it gives ai=13 ,13 times
it gives ai=29 ,29 times
it gives ai=17 ,17 times
13*13+17*17+29*29=1299 - 10 years agoHelpfull: Yes(5) No(4)
- @NEHA SHARMA:-lcm of 29,13,17 is 6409 which comes in else part i.e 0 also the number which is divisible by lcm of either 29 and 13 or 13 and 17 or 17 and 29 is divisible by lcm of 29 and 13 and 17,hence we need to reduce 1 in each case.hence solution will be 12*13+16*17+28*29
- 10 years agoHelpfull: Yes(1) No(0)
- @Rakesh, please tell me why it is like (12*13+16*17+28*29)
and not like
(17*17+13*13+29*29) - 10 years agoHelpfull: Yes(0) No(0)
- @Rakesh, please tell me why it is like (12*13+16*17+28*29)
and not like
(17*17+13*13+29*29) - 10 years agoHelpfull: Yes(0) No(0)
TCS Other Question