Archives
Trending
Support
Login
clear text
XML
Django
JavaScript
MATLAB
C
C++
C#
Python
SQL
Shell
Bash
Markdown
YAML
JSON
HTML
CSS
PHP
Java
Ruby
Go
Rust
Swift
Kotlin
Arduino
TypeScript
Perl
Autohotkey
Lua
SQF
R
Scala
Haskell
Groovy
Dart
Clojure
VB.NET
Objective-C
PowerShell
Bash
CoffeeScript
Verilog
pool_volume = int(input()) first_pipe = int(input()) second_pipe = int(input()) hours = float(input()) first_pipe_volume = first_pipe * hours second_pipe_volume = second_pipe * hours total_volume = first_pipe_volume + second_pipe_volume total_volume_percent = total_volume / pool_volume * 100 first_pipe_percent = first_pipe_volume / total_volume * 100 second_pipe_percent = second_pipe_volume / total_volume * 100 if total_volume <= pool_volume: print(f"The pool is {total_volume_percent:.2f}% full. Pipe 1: {first_pipe_percent:.2f}%. Pipe 2: {second_pipe_percent:.2f}%.") else: print(f"For {hours} hours the pool overflows with {total_volume - pool_volume:.2f} liters.")
Mark as private (unlisted)
for 30 minutes
for 6 hours
for 1 day
for 1 week
for 1 month
for 1 year
everlasting (like CCCP)