Beefy Boxes and Bandwidth Generously Provided by pair Networks
Syntactic Confectionery Delight
 
PerlMonks  

Re: localtime hour count

by rjsaulakh (Beadle)
on Apr 08, 2006 at 14:31 UTC ( #542047=note: print w/ replies, xml ) Need Help??


in reply to localtime hour count

<i have tried something very rudimentary hope u can refine and work on it let me know if you have something better

#!/usr/lib/perl -w use strict; use warnings; my $t1 = time(); print "$t1 \n"; sleep 5; my $t2 = time(); ; print ($t2) ; my $diff = $t2 - $t1; my $mDiff = int($diff / 60); my $sDiff = sprintf("%02d", $diff - 60 * $mDiff); print "diff = $diff -> $mDiff\:$sDiff\n";


Comment on Re: localtime hour count
Download Code
Re^2: localtime hour count
by ady (Deacon) on Apr 08, 2006 at 14:43 UTC
    Thanks rjsaulakh
    See my update above for another fix of the issue.
    Best regards,
    allan

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://542047]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (12)
As of 2014-12-25 16:47 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    Is guessing a good strategy for surviving in the IT business?





    Results (160 votes), past polls