| Run ID | 作者 | 问题 | 语言 | 测评结果 | Time | Memory | 代码长度 | 提交时间 |
|---|---|---|---|---|---|---|---|---|
| 145842 | 朱丰硕 | 07苹果和虫子 | C++ | Compile Error | 0 MS | 0 KB | 230 | 2026-01-25 19:14:58 |
#include<iostream> using namespace std; int main(){ int n,x,y; cin>>n>>x>>y; if(y%x>0){ if(n-y/x-1>=0){ cout<<n-y/x-1; } }else{ cout<<0; } }else if(n-y/x>=0){ cout<<n-y/x; } else { cout<<0; } }
Main.cc:13:3: error: expected unqualified-id before 'else'
}else if(n-y/x>=0){
^
Main.cc:16:2: error: expected unqualified-id before 'else'
else
^
Main.cc:20:1: error: expected declaration before '}' token
}
^