Run ID 作者 问题 语言 测评结果 Time Memory 代码长度 提交时间
70503 尚雨钒 07苹果和虫子 C++ Compile Error 0 MS 0 KB 233 2024-04-14 15:11:31

Tests(0/0):


Code:

#include<iostream> using namespace std; int main(){ int n,x,y; cin>>n>>x>>y; if(n<(y/x)) { cout<<0; } int c; else if(y%x!=0) { c=y/x+1 cout<<n-c; } else { c=y/x cout<<n-c; } return 0; }


Run Info:

Main.cc: In function 'int main()':
Main.cc:11:2: error: 'else' without a previous 'if'
  else if(y%x!=0)
  ^
Main.cc:14:3: error: expected ';' before 'cout'
   cout<