time() is declared in time.h not sys/time.h