Doubt in CB Number

Sir i m trying this code past 2 days but its showing arithmetic exception why?
here is my code

Hey Tejas

because in line 28 you do number%i (i starts from 0, giving error!)
Also I don’t see your approach to the solution working!
Think in recursive fashion!