This repository has been archived on 2024-12-16. You can view files and clone it, but cannot push or open issues or pull requests.
CodeBlocksPortable/WATCOM/samples/clibexam/ftime.c

15 lines
264 B
C

#include <stdio.h>
#include <time.h>
#include <sys/timeb.h>
void main()
{
struct timeb timebuf;
char *tod;
ftime( &timebuf );
tod = ctime( &timebuf.time );
printf( "The time is %.19s.%hu %s",
tod, timebuf.millitm, &tod[20] );
}