Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- N = int(input())
- M = int(input())
- x = int(input())
- y = int(input())
- if N > M:
- a = M
- b = N
- else:
- a = N
- b = M
- x1 = a - x
- y1 = b - y
- if x <= y:
- if x <= x1:
- if x <= y1:
- print(x)
- else:
- print(y1)
- else:
- if x1 <= y1:
- print(x1)
- else:
- print(y1)
- else:
- if y <= x1:
- if y <= y1:
- print(y)
- else:
- print(y1)
- else:
- if x1 <= y1:
- print(x1)
- else:
- print(y1)
Add Comment
Please, Sign In to add comment