#include <bits/stdc++.h>
using namespace std;
int main() {
  long a, b;
  char s;
  while (cin >> a >> s >> b) {
    long x;
    cin >> x;
    a = a * 60 + b;
    a = a + x;
    a = a % 1440;
    if (a / 60 < 10) {
      cout << 0 << a / 60;
    } else
      cout << a / 60;
    cout << ":";
    if (a % 60 < 10) {
      cout << 0 << a % 60 << "\n";
    } else
      cout << a % 60 << "\n";
  }
  return 0;
}
