#include #include #include int main() { time_t t = time(NULL); char buf[64]; struct tm *tm; setlocale(LC_ALL, ""); puts(asctime(tm = localtime(&t))); strftime(buf, sizeof(buf), "%a %b %e %T %Y", tm); puts(buf); strftime(buf, sizeof(buf), "%c", tm); puts(buf); return 0; }