We know that the terms in an A.P. are given by
a, a + d, a + 2d, a + 3d, ........ a + (n  2)d, a + (n  1)d
The sum of all these terms which is denoted by "S" is given by
This is obtained as follows. We know that
S = (a) + (a + d) + (a + 2d) + (a + 3d) + ..... +
{(a + (n  2)d)} + {(a + (n  1)d)}
Now we reverse the order and write it as shown below.
S = (a + (n 1) d) + (a + (n  2) d) + ......... +
(3d + a) + (2d + a) + (d + a) + a
On adding the respective terms we get
2S = {a + a + (n  1)d} + {a + d + a + (n  2)d}
+ ......... + {a + (n  2)d + a + d} +
{a + (n  1)d + a}
That is, we have:
2S = {2a + (n  1)d} + {2a + d + (n  2)d} +
............... + {2a + d + (n  2)d} +
{2a + (n  1)d}
Further simplifying we obtain
2s = {2a + (n  1)d} + {2a + d + nd  2d} +.............. +
{2a + d + nd  2d} + {2a + (n  1)d}
On simplification we obtain
2s = {2a + (n  1)d} + {2a + nd  d} + ......... +
{2a + nd  d} + {2a + (n  1)d}
2s = {2a + (n  1)d} + {2a + (n  1)d} + ....... +
{2a + (n  1)d} + {2a + (n  1)d}
Since 2 + 2 + 2 + 2 = 2(1 + 1 + 1 + 1) = 2 x 4,
2a + (n  1)d multiplied n times will be n.{2a + (n  1)d}. Therefore,
2s = n.{2a + (n  1)d}
or
s

= 
n/2 
{2a + (n  1)d} ............. (a) 
Since l = a + (n  1)d, equation (a) is also written as
s

= 
n/2 
{a + a + (n  1)d} or 
s

= 
n/2 
{a + l} 
Now we will find the sum of 20 terms when a = 5 and d = 2. Substituting these values in the formula, we obtain
s

= 
20 /2 
{2(5) + (20  1)2} 

= 
480 

This problem can also be solved by finding the last term which in this case happens to be T_{20} and it is given by T_{20} = 5 + (20  1)2 = 43. Therefore,
s 
= 
n /2 
{a + l} 

= 
20 /2 
{5 + 43} = 480. 
We observe that both these methods are essentially the same. With this background let us look at few more examples.
Example
For the series given below, find the 23rd and the 27th terms.
38, 36, 34, .............
We are given the first term that is a = 38. The common difference d is given by 36  38 = 2. The 23rd term is given by
T_{23} = a + 22d
= 38 + 22(2)
= 38  44 =  6
Similarly the 27th term is given by
T_{27} = a + 26d
= 38 + 26(2)
= 38  52