I want to implement a function which waits n seconds before retrying in case of a failure, but what would be the proper way of implementing the waiting-routine.
I figured that an endless loop with an if-clause might cause unwanted CPU-usage.
(do ((time (+ (get-universal-time) (- n 1)))
(time-cur (get-universal-time) (get-universal-time)))
((< time time-cur) nil))
Therefore: Would this be considered proper code or is there a more standard way?
Isn't SLEEP what your're looking for?
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With