Calculation formula of spring force

F = KX, f is elastic force, K is stiffness coefficient (or stubborn coefficient), X is the length of spring stretching (or pressing short). Example 1: when a spring with a stiffness coefficient of 100N / M is pulled with 5N force, the spring will be elongated by 5cm. Example 2: when a spring is subjected to a tensile force of 10N, its total length is 7cm, and when it is subjected to a tensile force of 20n, its total length is 9cm?