Beefy Boxes and Bandwidth Generously Provided by pair Networks
Think about Loose Coupling
 
PerlMonks  

Re: Optimise the script

by happy.barney (Friar)
on Mar 30, 2011 at 12:01 UTC ( [id://896398]=note: print w/replies, xml ) Need Help??


in reply to Optimise the script

if i understood it correctly, you want lines matching specific time interval.
  • get rid of Date::Manip, just calc your start time directly ($start = time - $n * 86_400)
  • use Time::Local::timegm to convert timestamp to epoch
  • compare epoch times (numbers)

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others pondering the Monastery: (3)
As of 2025-07-11 01:37 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?
    erzuuliAnonymous Monks are no longer allowed to use Super Search, due to an excessive use of this resource by robots.