Skip to content

Commit c048701

Browse files
authored
Merge pull request #1268 from paroche/patch-6
Update article.md
2 parents f8f402b + 78a6ffa commit c048701

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

1-js/06-advanced-functions/01-recursion/article.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ function pow(x, n) {
9696
9797
The maximal number of nested calls (including the first one) is called *recursion depth*. In our case, it will be exactly `n`.
9898
99-
The maximal recursion depth is limited by JavaScript engine. We can make sure about 10000, some engines allow more, but 100000 is probably out of limit for the majority of them. There are automatic optimizations that help alleviate this ("tail calls optimizations"), but they are not yet supported everywhere and work only in simple cases.
99+
The maximal recursion depth is limited by JavaScript engine. We can rely on it being 10000, some engines allow more, but 100000 is probably out of limit for the majority of them. There are automatic optimizations that help alleviate this ("tail calls optimizations"), but they are not yet supported everywhere and work only in simple cases.
100100
101101
That limits the application of recursion, but it still remains very wide. There are many tasks where recursive way of thinking gives simpler code, easier to maintain.
102102

0 commit comments

Comments
 (0)