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.
It's not perfect. When k = 12, n = 7. However, the n-th term for F is 13. We can check agaisnt this quickly with the same formula going forwards and backwards ONCE. instead of over a loop like everyone has been doing.
I should mention the relationship I gues. F_0 = 0, E = F_{3n}
Cookie support is required to access HackerRank
Seems like cookies are disabled on this browser, please enable them to open this website
Project Euler #2: Even Fibonacci numbers
You are viewing a single comment's thread. Return to all comments →
Fibonacci_index
It's not perfect. When k = 12, n = 7. However, the n-th term for F is 13. We can check agaisnt this quickly with the same formula going forwards and backwards ONCE. instead of over a loop like everyone has been doing.
I should mention the relationship I gues. F_0 = 0, E = F_{3n}