Run ID 作者 问题 语言 测评结果 Time Memory 代码长度 提交时间
98655 罗忠文 07苹果和虫子 C++ Compile Error 0 MS 0 KB 229 2024-11-23 12:07:13

Tests(0/0):


Code:

#include <iostream> #include<cmath> using namespace std; int main(int argc, char** argv) { int a; double b,c; cin>>a>>b>>c;//15 2 7 if(c%b!=0){ cout<<a-(c/b+1); }else{ cout<<a-c/b; } return 0; }


Run Info:

Main.cc: In function 'int main(int, char**)':
Main.cc:10:7: error: invalid operands of types 'double' and 'double' to binary 'operator%'
  if(c%b!=0){
       ^