Run ID 作者 问题 语言 测评结果 Time Memory 代码长度 提交时间
70180 牛延希 18排列骨头 C++ Time Limit Exceeded 1000 MS 256 KB 330 2024-04-13 17:57:18

Tests(0/1):


Code:

# include<iostream> using namespace std; int main(){ int a[114]={0},s=0,d=0,i=1; while(s<15){ i++; d++; if(a[i]==1) continue; if(d==9){ s++; a[i]=1; d=0; }if(i==30){ i=0; } }for(int i=1;i<=30;i++){ if(a[i]==0) cout<<i<<" "; } return 0; }