- 1
In calculation of factorial of a no. Which is the fastest method ( importing module, by recursion, by for loop)??
About factorial..
4 Réponses
+ 2
Recursion is a bit slower than loop due to overheads of function calls.
Loop is faster.
Module function performance depends on the library implementation. It is usually the fastest (for example, it can use pre-calculated values).
- 1
And what about using module?
- 1
Agreed...👍