Let the spring have a spring constant of k, x is the compression.
Restoration force = F = - k x, weight of person = m g
Potential energy of the person = mg h (h = x)
Potential energy of the spring = 1/2 k x²
When a person sits on the bed at rest, the Decrease in PE of person = Increase in PE of spring.
m g x = 1/2 k x²
k = 2 m g / x = 2 m g / 0.01meter = 200 mg N/m
When a person is dropped from a height of 0.250 meters:
m g (0.250+ x) = 1/2 k x²
mg (0.25+x) = 1/2 * 200 * mg * x²
0.25 + x = 100 x²
x = (1 +- √101 )/200 = 0.0552 m
Compression of the spring is 5.52 cm