Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include<iostream>
- #include <math.h>
- #include <iomanip>
- #include <cstdio>
- using namespace std;
- int main() {
- double x, y;
- cin >> x >> y;
- if(x == 0.0 && y == 0.0){
- printf("Origem\n");
- return 0;
- }
- if(x == 0.0){
- printf("Eixo X\n");
- return 0;
- }
- if(y == 0.0){
- printf("Eixo Y\n");
- return 0;
- }
- if(x < 0.0){
- if(y < 0.0){
- printf("Q3\n");
- return 0;
- }
- if(y > 0.0){
- printf("Q2\n");
- return 0;
- }
- }
- if(x > 0.0){
- if(y < 0.0){
- printf("Q4\n");
- return 0;
- }
- if(y > 0.0){
- printf("Q1\n");
- return 0;
- }
- }
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement