func_code_string: #include <bits/stdc++.h>   using namespace std;   template <class T>   string toStr(const T &x) {     stringstream s;     s << x;     return s.str();   }   template <class T>   int toInt(const T &x) {     stringstream s;     s << x;     int r;     s >> r;     return r;   }   vector<string> pals;   bool check(string s) {     for (int i = 0, j = s.size() - 1; i < s.size() / 2; i++, j--) {       if (s[i] != s[j]) return false;     }     return true;   }   void gen() {     for (int i = 0; i < 24; ++i) {       for (int j = 0; j < 60; ++j) {         string t1 = i < 10 ?  0  :   ;         string t2 = j < 10 ?  0  :   ;         string t = t1 + toStr(i) +  :  + t2 + toStr(j);         if (check(t)) pals.push_back(t);       }     }   }   int main() {     gen();     string line;     cin >> line;     if (line >  23:32 )       cout <<  00:00  << endl;     else {       vector<string>::iterator it = upper_bound(pals.begin(), pals.end(), line);       cout << pals[(it - pals.begin())] << endl;     }     return 0;   }   