; (3) for each of 2030 and 2031: 20,000 advanced practice registered nurse students; and (4) for 2032 and subsequent years, the greater of— (A) 20,000 advanced practice registered nurse students; or (B) the number of advanced practice registered nurse students needed to ensure the ratio of such students to the number of beneficiaries under the program under this title, the Medicaid program under title XIX, and the CHIP program under title XXI during the year is the same as such ratio for 2031. (f) Distribution of training positions (1) In general (A) Distribution The Secretary shall distribute the applicable percent (as defined in subparagraph (B)) of the total number of positions available for distribution under subsection (e) for a year as follows: (i) Each Hub shall receive a minimum number of positions, as determined by the Secretary. (ii) Any remaining positions available for distribution under this subparagraph shall be distributed to Hubs based on the following factors: (I) The number of advanced practice registered nurses that have graduated from participating applicable schools of nursing over the preceding 3 years. (II) The share of the relevant hospital referral region that is located in an area designated as a health professional shortage area under section 332(a)(1)(A) of the Public Health Service Act, as determined by the Secretary. (III) The share of the relevant hospital referral region that is located in a frontier State (as defined in section 1886(d)(3)(E)(iii)(II)). (IV) The share of the relevant hospital referral region that is located in a rural area (as defined in section 1886(d)(2)(D)). (V) Other factors determined appropriate by the Secretary. (B) Applicable percent defined For purposes of subparagraph (A), the term applicable percent means— (i) for 2026 and 2027, 100 percent; (ii) for 2028 and 2029, 95 percent