#include <bits/stdc++.h>
using namespace std;
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);
  long long hh, mm, M1, M2, h1;
  char ch;
  cin >> hh >> ch >> mm >> M1;
  M2 = (M1 + mm) % 60;
  h1 = (M1 + mm) / 60;
  hh = (hh + h1) % 24;
  if (hh == 0)
    cout << "00:";
  else if (hh <= 9)
    cout << "0" << hh << ":";
  else
    cout << hh << ":";
  if (M2 == 0)
    cout << "00";
  else if (M2 <= 9)
    cout << "0" << M2;
  else
    cout << M2;
  puts("");
  return 0;
}
