Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import sys
- points = {-4:6, -3:5, -2:4, -1:3, 0:2, 1:1, 2:0, 3:0, 4:0, 5:0, 6:0, 7:0}
- def calculator(handicap, index):
- score = handicap // 18 + (handicap % 18 >= index)
- return score
- def main():
- par = {}
- line1 = sys.stdin.readline()
- line1 = line1.strip().split()
- for i in range(1, 19):
- par[i] = line1[i-1]
- #print(par)
- line2 = sys.stdin.readline()
- line2 = line2.strip().split()
- #print(line2)
- index = {}
- for i in range(1, 19):
- index[int(line2[i- 1])] = i
- #print(index)
- scores = sys.stdin.readlines()
- for line in scores:
- handicap = line.strip().split()
- print(handicap[-19])
- total = int(handicap[-18:])
- print(total)
- if __name__ == '__main__':
- main()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement