#include int days[] = { 0, 31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31 }; int main() { char S[11]; int Y, M, D; scanf("%s", S); sscanf(S, "%d/%d/%d", &Y, &M, &D); if (Y % 4 == 0 and Y % 100 != 0 or Y % 400 == 0) days[2] = 29; D += 2; if (days[M] < D) { D -= days[M]; M++; if (12 < M) { Y++; M = 1; } } printf("%04d/%02d/%02d\n", Y, M, D); return 0; }