It was applied twice in the sample exam, 104 and 115. I was also wondering and checked
one of my books to understand the formula.
Let d be the deflection, dmax the max deflection, and dst the static deflection,
m*g/gc*(dmax+h)=1/2*k*dmax^2
m*g/gc=k*dst
=>1/2*dmax^2-k*dst*(h+dmax)=0...