+ 1
How i can make to display time from my computer using a c++ program?
Time synchronization
2 Answers
+ 1
using header file "ctime".
#include <ctime>
#include <iostream>
int main()
{
std::time_t
time=std::time(NULL);
std::cout<< std::asctime
(std::localtime(&time));
}
+ 1
Thank you for answering @mohd Fitri