3 ms·
It would also be significantly slower and potentially limited by stack depth. Even with the memoization some of these sequences get pretty long.
by brundolf 6y ago
It would also be significantly slower and potentially limited by stack depth. Even with the memoization some of these sequences get pretty long.
- smabie 6y agoI mean, a tail recursive solution wouldn't be.