#### Question

the first and the last terms of an A.P. are 17 and 350 respectively. If the common difference is 9, how many terms are there and what is their sum?

#### Solution

In the given problem, we have the first and the last term of an A.P. along with the common difference of the A.P. Here, we need to find the number of terms of the A.P. and the sum of all the terms.

Here,

The first term of the A.P (*a*) = 17

The last term of the A.P (*l*) = 350

The common difference of the A.P. = 9

Let the number of terms be *n*.

So, as we know that,

`l = a + (n - 1)d`

We get

`350 = 17 + (n - 1)9`

350 = 17 + 9n - 9

350 = 8 + 9n

350 - 8 = 9n

Further solving this,

`n = 342/9`

n = 38

Using the above values in the formula,

`S_n = (n/2) (a + l)`

`= (38/2)(17 + 350)`

= (19)(367)

= 6973

Therefore, the number of terms is n = 38 and the sum `S_n = 6973`