Limitation
The amount of the unused credit which may be taken into account under subparagraph (A) for any taxable year shall not exceed the amount (if any) by which the applicable tax limit for such taxable year exceeds the sum of—
(i)#
the credit allowable under subsection (a) for such taxable year determined without regard to this paragraph, and
(ii)#
the amounts which, by reason of this paragraph, are carried to such taxable year and are attributable to taxable years before the unused credit year.