#include <bits/stdc++.h>
using namespace std;
int main() {
  string s;
  cin >> s;
  int passed;
  cin >> passed;
  int tot = stoi(s.substr(0, 2)) * 60 + stoi(s.substr(3, 2)) + passed;
  tot %= 24 * 60;
  int m = tot % 60;
  tot -= m;
  int h = tot / 60;
  string s1 = to_string(h), s2 = to_string(m);
  if (s1.size() < 2) s1 = "0" + s1;
  if (s2.size() < 2) s2 = "0" + s2;
  cout << s1 << ':' << s2 << "\n";
}
