Run ID | 作者 | 问题 | 语言 | 测评结果 | Time | Memory | 代码长度 | 提交时间 |
---|---|---|---|---|---|---|---|---|
111515 | 张黄源 | 杀人游戏 | C++ | Compile Error | 0 MS | 0 KB | 339 | 2025-03-02 15:17:24 |
#include<bits/stdc++.h> using namespace std; int n,m; int hz[1000]; int main(){ cin>>n>>m; int ren=0; int bs=0; int live=n; while(live!=1){ ren++; if(ren==n+1){ ren=1; } if(live[ren]==1){ continue; } bs++; if(bs==m){ hz[ren]=1; cout<<ren; bs=0; live--; } } return 0; }
Main.cc: In function 'int main()': Main.cc:15:14: error: invalid types 'int[int]' for array subscript if(live[ren]==1){ ^