A mass is attached to a horizontal spring and compresses the string by 10 cm (position A). when it is released, it bounces back and stretches the spring by 10 cm (position B). Compare the potential energies at position A and B. The choices are 1). A>B, 2) A=B 3)A<B or 4) not enough information to tell.

LOL try it with a mass on the spring

as you compress it, U, the potential energy goes up
when you release it the mass hits max velocity as it passes zero.
then the kinetic energy dies and the potential climbs again
U = (1/2) k x^2
x^2 is the same for + or - x
A=B !!!!!