C / time.h / localtime
asctime, clock, ctime, difftime, gmtime, » localtime, mktime, strftime, time,
Funcion: localtime()
Sintaxis:
struct tm *localtime(const time_t *tiempoPtr);

Descripcion: La función localtime convierte el tiempo en formato condensado apuntado por tiempoPtr en el tiempo en formato separado, expresado como el tiempo local.


Ejemplo:
#include <stdio.h>
#include <time.h>
 
int main()
{
  time_t tiempo;
  char cad[80];
  struct tm *tmPtr;
 
  tiempo = time(NULL);
  tmPtr = localtime(&tiempo);
  strftime( cad, 80, "%H:%M.%S, %A de %B de %Y", tmPtr );
 
  printf( "La hora local es: %s\n", asctime(tmPtr) );
  printf( "La hora y fecha locales son: %s\n", cad );
 
  return 0;
}

Librerias C

Librerias ANSI C
   string.hcstring
   math.hcmath
   stdio.hcstdio
   time.hctime
   stdlib.hcstdlib
   ctype.hcctype
   locale.hclocale
   signal.hcsignal
   setjmp.hcsetjmp

Librerias Borland
   conio.h
   graphics.h