Solution of 1041 number !
please do not copy it rather watch it for learning purpose :)
#include <iostream>
#include <bits/stdc++.h>
using namespace std;
int main ()
{
double a,b;
cin >> a >> b;
if(a==0.0&&b==0.0)cout << "Origem" << endl;
if(a>0&&b>0) cout << "Q1" << endl;
if(a<0&&b>0) cout << "Q2" << endl;
if(a<0&&b<0) cout << "Q3" << endl;
if(a>0&&b<0) cout << "Q4" << endl;
if(a>0&&b==0)cout << ("Eixo X") << endl;
if(a<0&&b==0)cout << ("Eixo X") << endl;
if(b>0&&a==0)cout << ("Eixo Y") << endl;
if(b<0&&a==0)cout << ("Eixo Y") << endl;
return 0;
}
If you do not understand please leave a message here.
or mail us mechaboo786@gmail.com
or you can leave a message at fb . Link :- https://www.facebook.com/mechaboo/
please do not copy it rather watch it for learning purpose :)
#include <iostream>
#include <bits/stdc++.h>
using namespace std;
int main ()
{
double a,b;
cin >> a >> b;
if(a==0.0&&b==0.0)cout << "Origem" << endl;
if(a>0&&b>0) cout << "Q1" << endl;
if(a<0&&b>0) cout << "Q2" << endl;
if(a<0&&b<0) cout << "Q3" << endl;
if(a>0&&b<0) cout << "Q4" << endl;
if(a>0&&b==0)cout << ("Eixo X") << endl;
if(a<0&&b==0)cout << ("Eixo X") << endl;
if(b>0&&a==0)cout << ("Eixo Y") << endl;
if(b<0&&a==0)cout << ("Eixo Y") << endl;
return 0;
}
If you do not understand please leave a message here.
or mail us mechaboo786@gmail.com
or you can leave a message at fb . Link :- https://www.facebook.com/mechaboo/
Comments
Post a Comment