Submission
Status:
[PPPPPPP]
Subtask/Task Score:
{100/100}
Score: 100
User: Quinruj
Problemset: คิดถึงแม่
Language: cpp
Time: 0.003 second
Submitted On: 2025-09-17 20:58:07
#include <bits/stdc++.h>
#define ll long long
using namespace std;
int main(){
ios_base::sync_with_stdio(false);
cin.tie(NULL);
int n;cin>>n;
int mon[5] = {31,30,31,30,31};
for (int i = 0;i<5;i++){
for (int j = mon[i];j>0;j--,n--){
if (n == 0) n = 7;
if (i == 4 && j == 12) {
cout << n;
return 0;
}
}
}
}