how to get the gmt time in C. GMT stands for Greenwich Mean Time



#include
#include
#include


void main()
{
time_t t;
time(&t);
printf("Current Time is: %s\n", ctime(&t));
printf("GMT Time is: %s\n", asctime(gmtime(&t)));
getch();
}

No comments:

Post a Comment