#include <bits/stdc++.h>
using namespace std;
int main() {
  string s;
  int t, hh = 0, mm = 0, sum_mm = 0, h = 0, m = 0;
  cin >> s >> t;
  string s2 = "0";
  for (int i = 3; i < 5; i++) {
    s2 += s[i];
  }
  stringstream geek1(s);
  geek1 >> hh;
  stringstream geek2(s2);
  geek2 >> mm;
  hh *= 60;
  sum_mm = mm + hh + t;
  h = (sum_mm / 60) % 24;
  m = sum_mm % 60;
  if (h < 10 && m < 10)
    cout << "0" << h << ":0" << m;
  else if (h >= 10 && m < 10)
    cout << h << ":0" << m;
  else if (h >= 10 && m >= 10)
    cout << h << ":" << m;
  else
    cout << "0" << h << ":" << m;
  return 0;
}
