sum of 'n'odd number of consecutive numbers is divisible by 'n'.explain the reason
Answers
to find the sum of numbers from k to k+ n- 1, find the sum from 1 to k+ n- 1, (k+ n- 1)(k+ n)/2, then subtract the sum from 1 to k, k(k- 1)/2. That is ((k^2+ 2kn+ n^2- k- n)- (k^2- k))/2= (2kn+ n^2- n)/2= n((2k- n- 1)/2) so is divisible by n.
Answer:
Step-by-step explanation:
Since all even numbers are divisible and sum of n odd number is always an even number. And to generate the next odd number is x + 2, where x is the odd number.
Therefore we can construct such scenario as such:
where x =3 and using odd number generator x + 2
3, 5, 8, etc
now sum the first two consecutive odd numbers: 3+5= 8
Which can be written as (x + (x+2)) /2 => 3+3+2 => 6+2
Since, summing two even numbers always yield even numbers, then these summing of consecutive numbers could be divisible by n, and n is 2.