#define _USE_MATH_DEFINES #include //cin, cout #include //vector #include //sort,min,max,count #include //string,getline, to_string #include //fixed #include //setprecision #include //swap, pair #include //abs(int) #include //sqrt,ceil,M_PI, pow, sin #include //stringstream,getline #include //gcd, accumlate #include //deque #include //randam_device #include //numeric_limits using namespace std; constexpr long long int D_MOD = 1000000007; inline bool Judge_LeapYear(int year) { bool flg = false; if (year % 4 == 0) { flg = true; if (year % 100 == 0) { flg = false; if (year % 400 == 0) { flg = true; } } } return(flg); } inline int Days_Count(int year, int month) { int day = 0; if (month == 2) { if (Judge_LeapYear(year)) { day = 29; } else { day = 28; } } else { switch (month) { case 4: //day = 30; break; case 6: //day = 30; break; case 9: //day = 30; break; case 11: day = 30; break; default: day = 31; break; } } return day; } int main() { int y, m, d; scanf("%d/%d/%d", &y, &m, &d); if (d <= 26) { d += 2; } else { d += 2; int end_day = Days_Count(y, m); if (d > end_day) { d = d - end_day; m++; } } if (m == 13) { m = 1; y++; } cout << y << "/"; cout << setfill('0') << right << setw(2) << m; cout << "/"; cout << setfill('0') << right << setw(2) << d << endl; return 0; }