Extension in a vertically hanging rod Consider a vertical rod hanging from a ceiling. Neglect lateral contraction and frictional forces and air resistance and change in value of $g$ with height.
Case 1: In the absence of gravity, a rod is pulled by a force applied at the lowest point of the rod equal to its weight vertically downwards. Let the elongation be $x_1$.
Case 2: In the presence of gravity, the rod is subjected to no external forces (definitely, normal reaction of ceiling is considered) . Let its elongation be $x_2$.
Why $x_1 \ne x_2$?
 A: Suppose you have some weightless elastic strip and two weights of equal mass $M/2$. You arrange the weights in two different ways:

In the strip on the left the tensions in the two halves of the strip are different because the upper half is stretched by both weights while the lower half is stretched by just a single weight.
In the strip on the right the whole strip has the same tension.
Since the stretching of the strips is proportional to the tension there is no reason to suppose the overall stretching of the strips will be the same, and indeed it isn't.
If we now take the strip on the left and keep halving the weights so there are four, then eight, then sixteen, and so on weights spread out evenly along the strip we approach the massive rod in your question. The massive rod is conceptually an infinite array of weights spread out along its length. By contrast the weightless rod being pulled at the end is like the strip with all the weight concentrated at the end.
It should be intuitively obvious why the extensions of the rods are different, but intuitively obvious does not constitite a proof. If I were marking this question I would expect you to derive an equation for the total stretching of the rod under its own weight. You would do this by considering the extension of a small element of length $dx$ due to the weight of the part of the rod below it. The total stretching would then be given by integrating.
