有关C++的几个问题
在集成环境VC++6.0中有些错误可以帮忙解决下吗?我还没有入门,所以有很多不懂的地方。错误1:eh.h is only for C++
#include<iostream.h>
#include<math.h>
double max(doubke x,double y)
{
if(x>y)
return x;
else
return y;
}
void main()
{
double a,b,c;
cout<<"Input two numbers:\n";
cin>>a>>b;
c=max(a,b);
cout<<"the squart of maximum="<<sqrt(c)
}
错误2:error C2065: 'cin' : undeclared identifier
错误3:error C2297: '<<' : illegal, right operand has type 'char [20]'
错误4: error C2296: '>>' : illegal, left operand has type 'double '
warning C4013: 'max' undefined; assuming extern returning int