Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #https://acmp.ru/index.asp?main=task&id_task=712
- w, h, n = map(int, input().split())
- l = 0
- r = 10**18 + 1
- while r - l > 1:
- m = (r + l) // 2
- if (m // w) * (m // h) >= n:
- r = m
- else:
- l = m
- print(r)
Advertisement
Add Comment
Please, Sign In to add comment