At the end of each fiscal year of the operation of the municipally owned electric plant or water system, the profit from the operation of the plant or system shall be determined. If the council or city commission of the municipality shall determine that the profit or a part thereof shall be used toward the retirement of the bonded indebtedness of all the sewer or street improvement districts within the limits of such municipality, then the council, by ordinance as provided in § 14-199-203, shall allocate the amount to the various improvement districts within the limits of the municipality according to the following ratio: The total amount of bond and interest maturities of all sewer or street improvement districts within such municipality coming due during the particular fiscal year for which the profit of the plant and system was determined, shall be determined, and the ratio which the total bond and interest maturities of any sewer or street improvement district for such fiscal year bears to the total bond and interest maturities of all the sewer or street improvement districts for the fiscal year shall be the percentage used to allocate to each sewer or street improvement district, its proportion of the profit to be used for the retirement of the bonded indebtedness of any such district.