time(<ime); ctime(<ime);
time() returns the time as the number of seconds since the Epoch, 1970-01-01 00:00:00 +0000 (UTC). If tloc is non-NULL, the return value is also stored in the memory pointed to by tloc.
main(){ time_t *pot; time_t *pet; time_t pat; pot= ctime(pat); pet= time(pat); printf("%s", pot); printf("%s", pet);return 0;}
Pero es que las funciones no imprimen nada en pantalla y si hago algo como esto sigo sin obtener los datos de la fecha y hora Código: [Seleccionar]main(){ time_t *pot; time_t *pet; time_t pat; pot= ctime(pat); pet= time(pat); printf("%s", pot); printf("%s", pet);return 0;}