Fibonacci Returns
CodeChefOpen on judge ↗
Santa and Banta are buddies. Santa has a good sense of humour, but Banta is unable to or partially understands some jokes. Now Santa has with him N jokes he wishes to tell to Banta. Due to lack of time, he cannot tell all of them and has to choose R jokes for Banta. The total value of all the jokes he tells Banta is Fibonacci ( N C R ). Note that, Fibonacci(1)=Fibonacci(2)=1 and Fibonacci(n)=Fi
HINT LADDERno hints yet
L1 Observation
L2 Technique
L3 Approach
L4 Pseudo-code
🔒
L5 Full solution
L5 unlocks only if you insist twice
solution.cppC++17
CodeSearch Tutor
Hints, not spoilers — it won’t hand over the full solution unless you insist.
Sign in to chat with the tutor and save your progress.
Sign in to start