Exams for clearing arrears are held every next semester.You can clear it in any semester.
You can go through pervious year’s papers and can easily clear it. And it would be better if you clear all your pending arrears before sixth semester since from seventh semester onwards placement drives begin and some companies does not allow standing back logs.