Hello, I have a question as to calculate the term x of the fibonacci suceción ?, the problem is that x may be a number between 1 and 10000, I try to calculate with recursion but takes a long time, me You Might support with some other method to calculate, thank you.
Would need big int though.
Try matrix exponentation. Complexity with Binary pow is LOG(N). To get n-th Fibonacci number raise matrix to nth deegree.