I think that the opposition of forces doesn't "lose" energy and still keeps the conservation of energy.
I thought about analysing forces but the problem I came across is that i will need to do inegral on an equation with theta (which is kinda difficult I think)
Edit: btw thanks a lot for the...
I had quite a few attemps my current one is:
The energy at A is equal to the energy at B
At B with have no kenetic energy, and 2 spring energies
at A with have kenetic energy (and no spring energy?)
So 2*0.5kx^2 = 0.5mv^2
But I'm not sure if it is correct use x as the distance between A and B...