The document describes a PLC program for controlling a water filling and discharging process in a tank. The program uses two level sensors, one for high level and one for low level, to control a feeding valve and discharge valve. When the low level sensor is triggered, the feeding valve turns on to fill the tank, and when the high level sensor is triggered, the discharge valve turns on to empty the tank. The program is designed to maintain the water level between the two sensor points.