First of all, you cannot use the feature file to do any programming. So you cannot pass dynamic values from the feature file.
If you want to perform the above scenario with the listed values (10, 20, 30 and 40), you can add each of them as an example.
If you want the values to be dynamic / random, you can implement this in your step definition. In that case, rather than sending the values from your feature file, you would generate them in the implementation of your step definition. In that case I don't understand why you would want to run it 4 times.
To be honest, I don't understand your use case from the question. Can you explain the reason you want to send 4 dynamic values? (what is the problem you are trying to solve with this?)
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…