Run ID 作者 问题 语言 测评结果 时间 内存 代码长度 提交时间
37313 willson 开关灯 C++ 运行出错 0 MS 236 KB 404 2024-01-20 10:04:51

Tests(0/1):


#include<bits/stdc++.h> using namespace std; int main(){ int n,m,s[n+1]; cin>>n>>m; for(int i=1;i<m;i++){ if(i==1){ for(int i=0;i<n+1;i++){ s[i]+=1; } } if(i%2==0){ for(int i=0;i<n+1;i+=2){ s[i]-=1; } } if(i%3==0){ for(int i=0;i<n+1;i+=3){ s[i]+=1; } } } for(int i=0;i<n+1;i++){ if(s[i]==0){ cout<<s[i]; cout<<","; } } }


测评信息: