#include "includes"
int main() {
time_t rawtime;
struct tm * timeinfo;
char buffer [80];
time ( &rawtime );
timeinfo = localtime ( &rawtime );
string timetest;
timetest= strftime (buffer,80,"%Y-%m-%d",timeinfo);
puts (buffer);
}
now instead of print the time i want add the value of the time to a variable
like this
Today=%d;
Month=%m;
Year=%y;
so i can use it where i want and when i want thnx.