You can use strptime to convert string date to struct tm
struct tm tm; strptime("01/26/12", "%m/%d/%y", &tm);
And then type struct tm in the appropriate date format with strftime
char str_date[256]; strftime(str_date, sizeof(str_date), "%A, %d %B %Y", &tm); printf("%s\n", str_date);
Hal
source share