#include<iostream>
using namespace std;
int c;
int fun_div();
int fun_div(int a,int b){
if(a%b==0){
c=1;
cout<<"Solution Available :\t"<<c;
} else
{
c=0;
}
return c;
}
int main(){
int c;
int e,d;
cout<<"enter two values : \n";
cin>>e>>d;
cout<<endl;
}
误差在寻找两个数字的MOD,而不是编译程序:在寻找两个数字的MOD,而不是编译程序mod功能不工作为什么?
你可以缩进代码吗? – Danh
而你没有在'main'阴影'int c;'中调用'fun_div' – Danh
'int c;'全局。这可能会导致未来的悲伤。 – user4581301