1115.Quadrant in python
This is the solution of this problem in python:
M=list()
N=list()
pcount=0
count=1000
for i in range(0,count):
r,s=input().split()
M.append(r)
N.append(s)
x=int(M[i])
y=int(N[i])
if(x==0 or y==0):
break
else:
pcount+=1
for j in range(0,pcount):
a=int(M[j])
b=int(N[j])
if(a>0 and b>0):
print("primeiro")
elif(a>0 and b<0):
print("quarto")
elif(a<0 and b<0):
print("terceiro")
elif(a<0 and b>0):
print("segundo")
No comments