#include <sys/types.h>
#include <unistd.h> // declares getpid()
-#include <stdlib.h> // declares rand()
+#include <cstdlib> // declares rand()
#if defined(HAVE_GETTIMEOFDAY)
#elif defined(HAVE_TIMES_CLOCK)
-#include <time.h>
+#include <ctime>
#ifndef CLK_TCK
#include <sys/time.h>
#endif