#define _USE_MATH_DEFINES #include //cin, cout #include //vector #include //sort,min,max,count #include //string,getline, to_string #include //abs(int) #include //swap, pair #include //deque #include //INT_MAX #include //bitset #include //sqrt, ceil. M_PI, pow, sin #include //fixed #include //setprecision #include //stringstream #include //gcd, assumlate #include //randam_device #include //numeric_limits using namespace std; constexpr long long int D_MOD = 1000000007; inline vector SplitString(const string& str, const char key) { //文字列を任意の文字で分割 vector result; stringstream SS(str); string temp; while (std::getline(SS, temp, key)) { result.push_back(temp); } return(result); } int main() { string T; cin >> T; vector A = SplitString(T, ':'); int m = stoi(A[1]); int h = stoi(A[0]); m = m + 5; if (m >= 60) { h++; m = m % 60; } if (h >= 24) { h = h % 24; } cout << setfill('0') << right << setw(2) << h << ":"; cout << setfill('0') << right << setw(2) << m << endl; return 0; }