To read a coordinate point in a XY coordinate system and determine its Quadrant

x=int(input('Enter the values for X'))
 
y=int(input('Enter the values for Y'))

if x > 0 and y > 0:
  print ('x, y point lies in the First quandrant')
 
elif x < 0 and y > 0:
  print ('x, y point lies in the Second quandrant')
 
elif x < 0 and y < 0:
  print ('x, y point lies in the Third quandrant')

elif x > 0 and y < 0:
  print ('x, y point lies in the Fourth quandrant')

elif x == 0 and y == 0:
  print ('x, y point lies at the origin')

5 comments:

Unknown said...

This program is really helpful in my studies. Thanks a lot

shubam rajora said...

thanks for the content really a nice content it has helped me a lot
keep it up

Upender said...
This comment has been removed by the author.
Unknown said...

thank you for sharing wonderful information
python training in Hyderabad the best career

Jackie Co Kad said...


Great Article
Data Mining Projects


Python Training in Chennai

Project Centers in Chennai

Python Training in Chennai