Run ID 作者 问题 语言 测评结果 Time Memory 代码长度 提交时间
147364 赵奕杰 09闰年第n个月有多少天 C++ Accepted 1 MS 268 KB 240 2026-02-04 16:21:31

Tests(10/10):


Code:

#include<bits/stdc++.h> using namespace std; int n; int main(){ cin>>n; if(0>=n||n>12) cout<<"Invalid."; else if(n==1||n==3||n==5||n==7||n==8||n==10||n==12)cout<<"31"; else if(n!=2)cout<<"30"; else cout<<"29"; return 0; }