Two blocks of mass m1 and m2 are attached by a spring. A force F is exerted on m1, compressing the spring. For m1 to oscillate upwards after F is removed and lift m2, the minimum force F needed is (m1 + m2)g. The spring is compressed by an amount equal to the downward force of m1 divided by the spring constant. For the spring to lift m2 after oscillating due to F's removal, the additional compression must equal m2g divided by the spring constant. Adding these compressions equals the total downward force that must be balanced by F.