; (ii) all other liens on the property; and (iii) the amount of the exemption that the debtor could claim if there were no liens on the property, exceeds the value that the debtor’s interest in the property would have in the absence of any liens. (B) In the case of a property subject to more than 1 lien, a lien that has been avoided shall not be considered in making the calculation under subparagraph (A) with respect to other liens. (C) This paragraph shall not apply with respect to a judgment arising out of a mortgage foreclosure. (f) Notwithstanding sections 550 and 551 of this title, the debtor may exempt under subsection (b) of this section property that the trustee recovers under section 510(c)(2), 542, 543, 550, 551, or 553 of this title, to the extent that the debtor could have exempted such property under subsection (b) of this section if such property had not been transferred, if— (1) (A) such transfer was not a voluntary transfer of such property by the debtor; and (B) the debtor did not conceal such property; or (2) the debtor could have avoided such transfer under subsection (e)(1) of this section. (g) The debtor may avoid a transfer of property of the debtor or recover a setoff to the extent that the debtor could have exempted such property under subsection (f)(1) if the trustee had avoided such transfer, if— (1) such transfer is avoidable by the trustee under section 544, 545, 547, 548, 549, or 1041 of this title or recoverable by the trustee under section 553 of this title