+ 4
No infinite loop. You are not using returned value or no output statements..
cout<<obj.thirt(12);
0
Manav Roy
Your code does run into an infinite loop (tried with input 1234567). I haven't looked at the code closely yet to point out the problem (I'll certainly do it later and tell you), but why have you overcomplicated the code so much, when the kata is pretty straightforward. I'll suggest you to read the kata again, since they've given the whole algorithm to be followed in the question itself, and it's pretty simple compared to the code you've written.
- 2
Hi