hi,
i need to be able to get the current date but i want to be able to store the day, month and year in separate variables.
thanks
hi,
i need to be able to get the current date but i want to be able to store the day, month and year in separate variables.
thanks
Code:void get_date( int * month, int * day, int * year ) { struct tm *current; time_t timenow; time(&timenow); current = localtime(&timenow); *month = current->tm_mon+1; *day = current->tm_mday; *year = current->tm_year+1900; return; }
Code:#include <cmath> #include <complex> bool euler_flip(bool value) { return std::pow ( std::complex<float>(std::exp(1.0)), std::complex<float>(0, 1) * std::complex<float>(std::atan(1.0) *(1 << (value + 2))) ).real() < 0; }
thanks Sebastiani