#include <bits/stdc++.h>
using namespace std;
int main() {
  string s;
  cin >> s;
  char c = s[0], d = s[1];
  int x = (int)c - 48, y = (int)d - 48;
  int h = 10 * x + y;
  c = s[3], d = s[4];
  x = (int)c - 48, y = (int)d - 48;
  int m = 10 * x + y;
  long int a;
  cin >> a;
  int ah = 0;
  while (a >= 60) {
    a -= 60;
    ah++;
  }
  h += ah;
  m += a;
  ah = 0;
  while (m >= 60) {
    m -= 60;
    ah++;
  }
  h += ah;
  while (h >= 24) h -= 24;
  if (h < 10) cout << "0";
  cout << h << ":";
  if (m < 10) cout << "0";
  cout << m;
  return 0;
}
