We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
Solved it by using Binet's formular and fast doubling. This approach is more memory effecient than memorising the entire Fibonacci sequence in your data structure. Speed-wise I am getting an average of 0.14 sec for all test cases in C.
Cookie support is required to access HackerRank
Seems like cookies are disabled on this browser, please enable them to open this website
Is Fibo
You are viewing a single comment's thread. Return to all comments →
Solved it by using Binet's formular and fast doubling. This approach is more memory effecient than memorising the entire Fibonacci sequence in your data structure. Speed-wise I am getting an average of 0.14 sec for all test cases in C.