This function returns the number of milliseconds since the program started.
#include <stdio.h>
#include <time.h>
int main () {
clock_t Used;
int i;
i = 0;
while (i < 100000000) ++i; /* Delay loop */
Used = clock ();
printf ("The program ran for %i milliseconds",
Used);
return 0;
}
The program ran for 961 milliseconds
Copyright © 1999-, jhyoung,
revised 00/00/0