In the C Programming Language, the ctime function converts a calendar time (pointed to via timer) and returns a pointer to a string describing the nearby time equivalent.
The syntax for the ctime function in the C Language is:
char *ctime(const time_t *timer);
Parameters or Arguments
timer A pointer to an object of kind time_t that carries a time cost to convert.
The ctime feature returns a pointer to a string describing a local time pointed to by timer. It is equivalent to the following asctime characteristic call:
In the C Language, the required header for the ctime feature is:
In the C Language, the ctime feature can be used in the following versions:
Other C features that are comparable to the ctime function:
asctime feature difftime function gmtime function localtime characteristic mktime feature strftime feature time function