SyntaxFix
Write A Post
Hire A Developer
Questions
With C++11 you can now do
struct std::tm tm; std::istringstream ss("16:35:12"); ss >> std::get_time(&tm, "%H:%M:%S"); // or just %T in this case std::time_t time = mktime(&tm);
see std::get_time and strftime for reference