Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #ввод из консоли (скопировать таблицу из экселя и вставить) (руками)
- answ = {0: 0}
- while True:
- id, time, *treb = map(int, input().replace(';', ' ').split())
- answ[id] = max([answ[ask] for ask in treb]) + time
- print(max(answ.values()))
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement