Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- file = open('9.txt')
- count = 0
- for s in file:
- A = list(map(int, s.split()))
- A.sort()
- d = {elem: 0 for elem in A}
- for elem in A:
- d[elem] += 1
- A_rep = []
- A_unrep = []
- for elem in d:
- if d[elem] > 1:
- A_rep += [elem]
- else:
- A_unrep += [elem]
- if len(A_rep) == 0 and 3 * (A[0] + A[4]) <= 2 * (A[1] + A[2] + A[3]):
- count += 1
- print(count)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement