Determine the amount of time a sliding block is in contact with a spring.