#include <bits/stdc++.h>
using namespace std;
int main() {
  string s;
  cin >> s;
  int t;
  cin >> t;
  int h, m = 0;
  h += s[0] - '0';
  h = h * 10;
  h += s[1] - '0';
  m += s[3] - '0';
  m = m * 10;
  m += s[4] - '0';
  m += t;
  int k = m / 60;
  m = m % 60;
  h += k;
  h = h % 24;
  if (h > 23) {
    h = h - 24;
  }
  if (h < 10) {
    cout << 0;
    cout << h;
  } else {
    cout << h;
  }
  cout << ':';
  if (m < 10) {
    cout << 0;
  }
  cout << m;
}
