Talk:Date format

From Rosetta Code
Revision as of 14:21, 3 October 2008 by rosettacode>Mwn3d (Additionally...)

Input

I'm not exactly sure what is supposed to go on here. How is the date given? How would you like it formatted? I can give you POSIX time pretty easily in most languages...but I don't think you want that. --mwn3d 23:54, 10 November, 2007 (EST)

The Forth and Perl examples, as written, print the current date and time. Seems like a good choice. --Short Circuit 15:02, 10 February 2008 (MST)
The page has been tagged as "This task has been clarified". But it has not been clarified. It still does not say how the date is given. I agree that current date would be a good choice, that should be added to the task description. --PauliKL 09:39, 3 October 2008 (UTC)
If any output format is to be chosen then that should be one of ISO 8601, I suppose. --Dmitry-kazakov 12:54, 3 October 2008 (UTC)
ISO sounds like a great idea. If we want to make things the same across all languages, why not use a standard, right? Also, I think the current date should be used. It's the easiest to specify. --Mwn3d 14:19, 3 October 2008 (UTC)

Leading zeros

While I'm sure that there should be no leading zeros in the format where words occur, I suspect that the intention is for Febrary 1st, 2008 to be formatted "2008-02-01" not "2008-2-1". Does the specification need to be altered to reflect this? --TBH 22:17, 8 February 2008 (MST)

ISO 8601 requires leading zeros, but the task is still not clarified. Personally I think that it mangles two separate issues:
  • splitting a time stamp into fields, like month number, day of week etc in presence of a given time zone
  • formatted output of the fields
Does it really matter if the output should be 01:02:2008, 2008/01/02, 1/II/2008 etc? --Dmitry-kazakov 12:54, 3 October 2008 (UTC)