In computing amounts or exclusions under this section with respect to any urban county, there shall be excluded units of general local government located in the county the populations of which are not counted in determining the eligibility of the urban county to receive a grant under this subsection, except that there shall be included any independent city (as defined by the Bureau of the Census) which—
(A) is not part of any county;
(B) is not eligible for a grant pursuant to subsection (b)(1);
(C) is contiguous to the urban county;
(D) has entered into cooperation agreements with the urban county which provide that the urban county is to undertake or to assist in the undertaking of essential community development and housing assistance activities with respect to such independent city; and
(E) is not included as a part of any other unit of general local government for purposes of this section.
Any independent city which is included in any fiscal year for purposes of computing amounts pursuant to the preceding sentence shall not be eligible to receive assistance under subsection (d) with respect to such fiscal year.