Advertisement
Guest User

Untitled

a guest
Sep 15th, 2019
167
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.46 KB | None | 0 0
  1. left = None
  2. right = None
  3. top = None
  4. bottom = None
  5. n = int(input())
  6. points = []
  7. for i in range(n):
  8. x, y = map(int, input().split())
  9. if -abs(x) < y < abs(y):
  10. points.append((x, y))
  11. if left is None or x < left[0]:
  12. left = (x, y)
  13. if right is None or x > right[0]:
  14. right = (x, y)
  15. if top is None or y > top[1]:
  16. top = (x, y)
  17. if bottom is None or y < bottom[1]:
  18. bottom = (x, y)
  19. for elem in points:
  20. print(elem)
  21. print(
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement