Converts a broken-down time (see the localtime function for more information) into a 26-character string in the following form:
Sun Sep 16 01:03:52 1984\n\0
All fields have a constant width.
This function is nonreentrant.
#include <time.h> char *asctime (const struct tm *timeptr);
The asctime function converts the contents of tm into a 26-character string, as shown in the previous example, and returns a pointer to the string. Subsequent calls to asctime or ctime may point to the same static string, which is overwritten by each call.
See the localtime function in this section for a list of the members in tm.
x | A pointer to the string. |