Beefy Boxes and Bandwidth Generously Provided by pair Networks
Come for the quick hacks, stay for the epiphanies.
 
PerlMonks  

Re: Optimal Date conversion? (Too much information)

by friedo (Prior)
on Dec 29, 2004 at 16:28 UTC ( [id://418018]=note: print w/replies, xml ) Need Help??


in reply to Optimal Date conversion? (Too much information)

I would just use the list context of localtime for this.
my @d = ( localtime )[5,4,3,2,1,0]; $d[0]-=100; # fix the year printf("%02.d-%02.d-%02.d_%02.d:%02.d:%02.d", @d);

Output:
04-11-29_11:29:37

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others lurking in the Monastery: (6)
As of 2024-04-23 15:33 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found