65,210
社区成员
发帖
与我相关
我的任务
分享if(m=1) //判断相等用==,不是=(这个是赋值)
{
cout < <"Three blind mice" < <endl;
} #include <iostream>
using namespace std;
char hanshu(char);
void hanshu(int m)
{
if(m==1) //用判断的==而不是赋值的=
{
cout <<"Three blind mice" <<endl;
}
if(m==2)
{
cout <<"See how zhey run" <<endl;
}
}
int main()
{
hanshu(1);
hanshu(1);
hanshu(2);
hanshu(2);
return 0;
}