Here's the equation - you are given this in your exam, so you don't need to learn it. The elastic potential energy (in joules) is 0.5 multiplied by the spring constant, multiplied by the extension (in metres) squared.

11