Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- dates = {}
- with open('input.txt') as f:
- for line in f:
- line = line.split()
- if len(line) < 3:
- continue
- date = s[0]
- time = s[1]
- price = int(s[2])
- if(date not in dates):
- dates[date] = []
- dates[date].append(price)
- answer = 1
- for date in dates:
- minmax = 1
- for i in range(len(dates[date])):
- for j in range(i + 1, len(dates[date])):
- minmax = max(minmax, dates[date][j] / dates[date][i])
- answer *= minmax
- answer -= 1
- answer *= 100
- print(answer)
Advertisement
Add Comment
Please, Sign In to add comment