#!/fellow/monks.pl
I need to calculate how long it takes to do a particular task. The attached sample works for second intervals, however, I need to be able to count down to the milli second. How can I achieve that ?
#!/usr/bin/perl $start = time; sleep(2); #or some other crazy pieces of code $end = time; $length = $end - $start; print "It took us $length seconds to do the job.\n";
Thanks!
|\/| _. _ _ ._
| |(_|_>_>\/| |
/
In reply to Count the milliseconds by Massyn
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |