Sunday, June 12, 2016

SOLUTION OF URI 1041


//   question of uri 1041 Coordinates of a Point
// 1041   (Mahmud_Jamil) BRUR





#include<stdio.h>
int main ()
{
float x,y;
scanf("%f %f",&x,&y);

if(x>0 && y>0) {
printf("Q1\n");
}
else if(x<0 && y>0) {
printf("Q2\n");
}
else if(x<0 && y<0) {
printf("Q3\n");
}
else if(x>0 && y<0) {
printf("Q4\n");
}
else if(x==0 && y==0) {
printf("Origem\n");
}
else if(x==0) {
printf("Eixo Y\n");
}
else {
printf("Eixo X\n");
}
return 0;
}