Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit 8754e36

Browse files
Solution Accepted
1 parent 07b6f02 commit 8754e36

File tree

1 file changed

+32
-0
lines changed

1 file changed

+32
-0
lines changed
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
#!/bin/python3
2+
3+
import math
4+
import os
5+
import random
6+
import re
7+
import sys
8+
9+
def compareTriplets(a, b):
10+
score = [0,0]
11+
for i in range(len(a)):
12+
if (a[i] > b[i]):
13+
score[0] = score[0] + 1
14+
elif(a[i] < b[i]):
15+
score[1] = score[1] + 1
16+
else:
17+
pass
18+
return score
19+
20+
if __name__ == '__main__':
21+
fptr = open(os.environ['OUTPUT_PATH'], 'w')
22+
23+
a = list(map(int, input().rstrip().split()))
24+
25+
b = list(map(int, input().rstrip().split()))
26+
27+
result = compareTriplets(a, b)
28+
29+
fptr.write(' '.join(map(str, result)))
30+
fptr.write('\n')
31+
32+
fptr.close()

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /