> perl -e '$days=12016; $seconds=$days*86400; print localtime($seconds) . "\n"'
Sun Nov 24 16:00:00 2002

HTH,
 - Mark

On Wed, 29 Jan 2003, Kenneth Jideofor [ MTN - Ikoyi ] wrote:

> Date: Wed, 29 Jan 2003 19:57:10 +0100
> From: "Kenneth Jideofor [ MTN - Ikoyi ]" <[EMAIL PROTECTED]>
> To: [EMAIL PROTECTED]
> Subject: Date Conversion in Perl
>
> Hi,
>
> Given a number of days, it is expected to determine the real date from Jan
> 1, 1970.
> The real date should be in the following format: Year-Month-Day.
>
> How do I implement this task using Perl.
>
> For example, write a Perl script to convert 12016 days to its real date from
> Jan 1, 1970.
>
> Regards,
> Ken
>
> _______________________________________________
> ActivePerl mailing list
> [EMAIL PROTECTED]
> To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
>
_______________________________________________
ActivePerl mailing list
[EMAIL PROTECTED]
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs

Reply via email to