unexpected end of file found ??!!
来源:百度知道 编辑:UC知道 时间:2024/05/26 18:11:54
#include "stdafx.h"
#include <iostream>
using namespace std;
int max (int x,int y,int z)
int main(int argc, char* argv[])
{ int a,b,c;
cout <<"请输入a:";
cin >>a;
cout <<endl;
cout <<"请输入b:";
cin >>b;
cout <<endl;
cout <<"请输入c:";
cin >>c;
max=max (a,b,c);
return 0;
}
int max (int x,int y,int z)
{int t;
if x>y
t=x;
else
t=y;
if z>t
cout<<z<<endl;
else
cout<<t<<endl;
}
#include <iostream>
using namespace std;
int max (int x,int y,int z)
int main(int argc, char* argv[])
{ int a,b,c;
cout <<"请输入a:";
cin >>a;
cout <<endl;
cout <<"请输入b:";
cin >>b;
cout <<endl;
cout <<"请输入c:";
cin >>c;
max=max (a,b,c);
return 0;
}
int max (int x,int y,int z)
{int t;
if x>y
t=x;
else
t=y;
if z>t
cout<<z<<endl;
else
cout<<t<<endl;
}
以下为修改后的程序,修改的地方看注释
#include <iostream>
using namespace std;
int max (int x,int y,int z); //注释加分号
int main(int argc, char* argv[])
{
int a,b,c;
cout <<"请输入a:";
cin >>a;
cout <<endl;
cout <<"请输入b:";
cin >>b;
cout <<endl;
cout <<"请输入c:";
cin >>c;
int maxv=max (a,b,c); //变量名与函数名相同
cout<<"max="<<maxv<<endl;
return 0;
}
int max (int x,int y,int z)
{
int t;
if (x>y)
t=x;
else
t=y;
if (z>t)
t=z; //这里没语法错误,但与求最大值意思不对
return t; //不要忘了返回值
}
FPC unexpected end of file怎么解决?
C++编译错误 unexpected end of file found
unexpected $end 在php中什么意思啊?
unexpected end of file while looking for precompiled header directive
cpp(203) : fatal error C1004: unexpected end of file found
同一个程序tp没事/fp unexpected end?
ABORT: 10008 ,unexpected end of file怎么处理??
在c++中,编译时出现fatal error C1004: unexpected end of file found是什么意思?
fatal error C1010: unexpected end of file while looking for precompiled header directive
fatal error C1071: unexpected end of file found in comment这个是什么意思啊?