In every case under section 22 or section 23, the cost of executing or completing the work shall be payable by such person or persons deriving benefit from the water-course as the Collector may in each case determine. ...