Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- volume = float(input())
- pipe1 = float(input())
- pipe2 = float(input())
- hour = float(input())
- poolV = (pipe1 + pipe2) * hour
- poolP = poolV / volume
- if volume >= poolV:
- print(f'The pool is {poolP * 100:.2f}% full. Pipe 1: {pipe1 / poolV * hour * 100:.2f}%. Pipe 2: {pipe2 / poolV * hour * 100:.2f}%.')
- else:
- print(f'For {hour} hours the pool overflows with {poolV - volume:.2f} liters.')
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement