Buffer which holds result of ctime() is shared across all calls to it, so each succesive call to ctime() will overwrite previous data.
Possible solutions:
1 2 3 4 5 6 7 8 9 10 11 12 13 14
constchar* beforeTime=DateTime::GetDate();
cout << "Execution Time : " << beforeTime << "\t";
//Wait here
constchar* afterTime=DateTime::GetDate();
cout << afterTime << endl;
//or
char beforeTime[100];
strncpy(beforeTime, DateTime::GetDate(), 99);
//wait here
char afterTime[100];
strncpy(afterTime, DateTime::GetDate(), 99);
//output here