#include #include #include int main (void) { setlocale(LC_ALL, "de_DE.ISO8859-1"); time_t tt = time(NULL); struct tm *t = localtime(&tt); char s[100]; strftime(s, 100, "%p", t); printf("%s\n", s); return 0; }