We don't bite newbies here... much | |
PerlMonks |
Convert Time to Epoch Using External Variableby Anonymous Monk |
on Feb 04, 2015 at 14:39 UTC ( [id://1115524]=perlquestion: print w/replies, xml ) | Need Help?? |
Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question: Hope someone will be able to help me. I tried looking at previous answers and questions but did not find a solution. Restrictions: Perl v. 5.8.4, Solaris 10, default modules I would like to convert a specified time (e.g., Wed Feb 4 12:34:56 2015) to an epoch time using one line of Perl. I was thinking about using: echo "56,34,12,4,1,115"|perl -MPOSIX -e 'print mktime(<stdin>)'However, <stdin> is treated as just one variable instead of all the variables.
Back to
Seekers of Perl Wisdom
|
|