The mathematical relationship between force and extension for a spring is F = -kx , where F is the restoring force, k is the spring constant and x is the extension. If a box that weighs 40 N is hung from a spring of content 400 N/m, then the extension is equal to x = -F / k = -400 / 40 = -10 cm. The negative sign simply shows the extension and restoring force are in opposite directions. The answer is 10 cm.