// Using the ctime() function
#include <iostream>
#include <ctime>
using namespace std;

int main()
{
  time_t t;

  time(&t);
  cout << "Current date and time are\n" << ctime(&t) << endl;

  return 0;
}
