#include<iostream> #include<cmath> #include<iomanip> using namespace std; int ma
ID: 3614532 • Letter: #
Question
#include<iostream>#include<cmath>
#include<iomanip>
using namespace std;
int main()
{double x,y,num,denom;
do
{cin>>x;
num= (-4*pow(x,3.0)+12*pow(x,2.0)-3*x-5);
denom= (sqrt(3*pow(x,2.0))+1)+10*abs(x-1.5);
y=(num/denom);
cout<<setprecision(3)<<"x= "<<x;
cout<<setprecision(6)<<" y="<<y<<" ";
if(y<0)
cout<<"Y IS NEGATIVE ";
if(y==0)
cout<<"Y EQUALS ZERO ";
if(y>0)
cout<<"Y IS POSITIVE ";
}
while(x>=-4//x<=3.5);
system ("pause");
return 0;
}
I cant compile it cause Im missing a ; supposedly but cant find it!plz help!
Explanation / Answer
LOL I figured it out. I was using backslash instead of ||.got it now and || was wrong choice anyway
Related Questions
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.