c 언에서 제공하는 시간 관련 함수 입니다. time.h 파일에 시간 관련함수가 정의 되어 있습니다. 

UltraEdit source file - ����1
#include<stdio.h>
#include<time.h>
 
int main(void)
{
   time_t   current_time;

   time( &current_time);

   printf( "%ld \n", current_time);
   printf( ctime( &current_time));

   return 0;
}


시간은 1970년 1월 1일 0시 부터 함수를 호출할 때가지의 초단위를 나타냅니다. 그렇기 때문에 직관적으로 시간을 확인하기 어렵습니다.  사람이 보기 쉬운 형태로 ctime()함수를 사용하면 됩니다.