I'm not quite sure if this problem is pre-calculus, but there is no specified way to solve it, and it's giving me a lot of trouble.
An empty tank with 1 gate at each end is filled and drained with water. You start a 20 second timer, and every 1.323 seconds after the timer is started gate 1 opens and shuts instantly letting in 150 L of water. Also every 2 seconds after the timer has been started gate 2 opens and shuts instantly letting 60 L of water out. After the 20 seconds has elasped, how much water has been drained from the tank, and how much is remaining in the tank?