#include <stdio.h>
#include <sys/time.h>
#include <sys/time.h>
int main( void )
{
char buf[128];
struct timeval sCurTimeVal;
struct tm *sTm;
gettimeofday (&sCurTimeVal, NULL);
sTm = localtime(&sCurTimeVal.tv_sec);
sprintf( buf, "%04d %02d %02d %02d %02d %02d %04d", sTm->tm_year+1900, sTm->tm_mon+1, sTm->tm_mday, sTm->tm_hour, sTm->tm_min, sTm->tm_sec, sCurTimeVal.tv_usec/100);
printf("%s",buf);
return 0;
}