Farz0l1x

Untitled

Jun 14th, 2023
149
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.25 KB | None | 0 0
  1. file = open('20A.txt')
  2. n = int(file.readline())
  3. kx = 0
  4. ky = 0
  5. k = 0
  6. for i in range(n):
  7. x, y = map(int, file.readline().split())
  8. if x == 0:
  9. kx += 1
  10. elif y == 0:
  11. ky += 1
  12. else:
  13. k += 1
  14. print(k * kx * ky)
Advertisement
Add Comment
Please, Sign In to add comment