+ 2
Why is it showing this?
The code is showing unlimited erorrs!!! But why? https://code.sololearn.com/cW4l3jwJIQRG/?ref=app
3 Answers
+ 3
you created a recursion, that means the function counter() calls itself. But the number of recursive steps s limited. As Nandini mentioned you must create a condition that terminates the infinite running of the code. Like :
if num == 500:
return
+ 1
It is running infinite times
U need to write stop condition
0
But somehow I printed Infinite errors!!!