The problems in pipes and cisterns are almost the same as those of Time and Work problems, but with a bit difference as negative work comes into play due to leakage or drain pipes in the questions.
Let us understand this with examples.
Example 1; If a pipe fills a tank in 10 hours and a leak in the bottom empties it in15 hours, when both function simultaneously then
Net work is Positive.
Thus tank will be filled in 30 hours.
Example 2; If a pipe fills a tank in 5 hours and a leak empties in 4 hours, when both function simultaneously then
Net work is Negative.
Thus tank will be emptied in 20 hours.