If when the cause of action shall accrue against any person he shall be out of the state, such action may be commenced within the terms herein respectively limited after the return of such person into this state; and if after such cause of action shall have accrued, such person shall depart from and reside out of the state, the time of his absence shall not be deemed or taken as any part of the time limited for the commencement of such action; provided that the provisions of this section shall not apply to an action for the foreclosure of any real estate mortgage, or to the foreclosure of any real estate mortgage by advertisement.
SDCL 15-2-20