When the ball is at height 31 cm it possess potential energy which is given as,
When the ball rolls from height along the ruler the potential energy will be converted into kinetic energy.
According to conservation of energy,
Plug in the known expression,
Substitute the known values,
Thus, the kinetic energy of the ball is 0.140 J.