in reply to How to sleep before the next fork kicks off?
G'day dr.jekyllandme,
Firstly, there is a clear disconnect between the code sleep(1) and your description which variously has "n seconds" and "2 minutes". See the documentation for sleep and decide exactly what period you want.
If "2 minutes" was correct, then sleep($x * 120); would be appropriate.
From your description, you probably want to sleep() before you start().
For finer control over the delay, use the core Time::HiRes module.
-- Ken
|
|---|