There's probably hundreds of different way to code it. The only way it matters for you is guiding you in the direction so you can think about this logically to complete your assignment. In order to do that, we need to see the work you done already.
Speaking in generality, what one need here is 3 different states.
1. Pump1 On
2. Pump2 On
3. Both off.
Think of a way to create 3 states with the button and you will be 90% there.