#### Question

200 logs are stacked in the following manner: 20 logs in the bottom row, 19 in the next row, 18 in the row next to it and so on. In how many rows are the 200 logs placed and how many logs are in the top row?

#### Solution

It can be observed that the numbers of logs in rows are in an A.P.

20, 19, 18…

For this A.P.,

a = 20

d = a_{2} − a_{1} = 19 − 20 = −1

Let a total of 200 logs be placed in n rows.

S_{n} = 200

`S_n = n/2[2a+(n-1)d]`

`200 = n/2[2(20)+(n-1)(-1)]`

400 = *n* (40 − *n* + 1)

400 = *n *(41 − *n*)

400 = 41*n* − *n*^{2}

*n*^{2} − 41*n *+ 400 = 0

*n*^{2} − 16*n* − 25*n* + 400 = 0

*n *(*n* − 16) −25 (*n* − 16) = 0

(*n *− 16) (*n* − 25) = 0

Either (*n* − 16) = 0 or *n* − 25 = 0

*n* = 16 or *n* = 25

*a*_{n} = *a* + (*n* − 1)*d*

*a*_{16} = 20 + (16 − 1) (−1)

*a*_{16} = 20 − 15

*a*_{16} = 5

Similarly,

*a*_{25} = 20 + (25 − 1) (−1)

*a*_{25} = 20 − 24

*= −*4

Clearly, the number of logs in 16^{th} row is 5. However, the number of logs in 25^{th} row is negative, which is not possible.

Therefore, 200 logs can be placed in 16 rows and the number of logs in the 16^{th} row is 5.