+ 2
Sololearns Swift Simulator Stack Spce
Hello Everybody, I just wrote my second Swift program in the Code Playgrond. its 'https://code.sololearn.com/cYs4V1NN2Lcx/#swift', fact_fib_numbers. This code uses the recursive definition of Factorial and Fibonacci numbers. fib(n:Int)->Int is a doubly recursive function, but why can't I calulate anything over fib(n:8)????? Have I run out of stack space in the simulator??? If I run the program for the range 0...10, prints 0...8 Fibonacci numbers, then waits a long time and finaly quits. no error message. What's going on???
2 Respuestas
+ 2
really? it works fine for me, so it may be related to your device or your internet connection
+ 2
I just loaded the new SoloLearn app on my new iPhone. Now I don't have any problems with stack space that I had when I was using the web interface from my laptop. With the app the execution is almost instantaneous.