; and (2) in section 1915, by adding at the end the following new subsection: (l) State plan amendment option to provide medical assistance for certain individuals who are patients in certain institutions for mental diseases (1) In general With respect to calendar quarters beginning during the period beginning October 1, 2019, and ending September 30, 2023, a State may elect, through a State plan amendment, to provide medical assistance for items and services furnished to an eligible individual who is a patient in an eligible institution for mental diseases in accordance with the requirements of this subsection. (2) Payments Subject to paragraphs (3) and (4), amounts expended under a State plan amendment under paragraph (1) for services described in such paragraph furnished, with respect to a 12-month period, to an eligible individual who is a patient in an eligible institution for mental diseases shall be treated as medical assistance for which payment is made under section 1903(a) but only to the extent that such services are furnished for not more than a period of 30 days (whether or not consecutive) during such 12-month period. (3) Maintenance of effort (A) In general As a condition for a State receiving payments under section 1903(a) for medical assistance provided in accordance with this subsection, the State shall (during the period in which it so furnished such medical assistance through a State plan amendment under this subsection) maintain on an annual basis a level of funding expended by the State (and political subdivisions thereof) other than under this title from non-Federal funds for— (i) items and services furnished to eligible individuals who are patients in eligible institutions for mental diseases that is not less than the level of such funding for such items and services for the most recently ended fiscal year as of the date of enactment of this subsection or, if higher, for the most recently ended fiscal year as of the date the State submits a State plan amendment to the Secretary to provide