If the sum of first 7 terms of an AP is 49 and that of first 17 terms is 289.Find the sum of first n terms

S _{7} = 7/2 [2a+(6)d]

49* 2/7 = 2a+6d

7*2 = 2a+6d

14 = 2a+6d........(1)

s_{17}= 17/2 (2a+16d)

289*2/17 = 2a+16d

17*2 = 2a + 16d

34 = 2a + 16d .........(2)

subtracting eq. 2 from 1 we will get

20 = 10 d

so ,d = 2

putting d = 2 in eq. 1

14 = 2a + 6 * 2

14 = 2a + 12

14 - 12 = 2a

2a = 2

a = 1

s_{n}= n/2 [2a+ (n-1)d]

=n/2[2(n)]

=n^{2}

s_{n =}n^{2}

so sum of first natural number = n^{2}