A. A county’s share of the matching funds may be provided by such county in cash or an amount not in excess of twenty-five per cent of such share may be credited for other expenditures of the county in similar counseling services. A county providing matching funds for a federal program for similar services shall be given credit as contributing cash under this subsection in an equal amount for purposes of matching funds for state programs. The amount of such credit to be allowed shall be determined by the court.

B. The legislature shall annually appropriate to the supreme court an amount sufficient to carry out the state’s obligation pursuant to this article and shall specify the maximum amount payable to each participating county which shall include a basic amount of money made available in equal amounts to each participating county and the remainder of the appropriation to be made available to each participating county based upon the percentage that each such county’s juvenile population is to the total juvenile population of the participating counties.