At 2:51 AM -0500 2001/11/25, Adam Russell wrote:
>How do I get the current system time in milliseconds?
Check out "Time::HiRes" (High resolution alarm, sleep, gettimeofday,
interval timers) in the latest MacPerl 5.6.1b2 release. It's worth the
upgrade for me.
#!perl
use Time::HiRes qw(gettimeofday);
for (1..10) {
($seconds, $microseconds) = gettimeofday; # since the epoch
print "$seconds $microseconds\n";
}
__END__
On my iBook this prints...
3089528308 430620
3089528308 446472
3089528308 447951
3089528308 448961
3089528308 449932
3089528308 450913
3089528308 452126
3089528308 453134
3089528308 454110
3089528308 455082