Confusion about springs and hooke's law

There is a statement in my book i can't really understand. "To stretch a spring, we must do work. We apply equal and opposite forces to the ends of a spring and gradually increase the forces. We hold the left end stationary, so the force we apply at this end does no work.The force at the moving end does do work" ... How is it we apply force on both ends of a spring. Doesn't hook's law apply for the end we actually stretch. F=kx??? Kindly Clarify.. Thanks!
 PhysOrg.com physics news on PhysOrg.com >> Kenneth Wilson, Nobel winner for physics, dies>> Two collider research teams find evidence of new particle Zc(3900)>> Scientists make first direct images of topological insulator's edge currents
 Recognitions: Science Advisor If you apply force to only one end of the spring, the entire spring will simply accelerate. F=ma still works. If you want to stretch or compress the spring, something or someone must hold the other end of the spring stationary. In other words, the net force on the spring needs to be zero.
 But then if it is stationary, how does the spring produce a force on the wall = -Fx??

Recognitions: