This is a question asking about springs using Hooke's Law. Hooke's Law relates the spring constant with the displacement from equilibrium by the following relationship:
Fs = -kx
When the spring is compressed, x takes a negative value
Fs = -kx
<=> -(340N*m-1)(-0.5m)
Fs = 170N
Cheers!