Error in fast exponentiation

I am unable to figure out error in implementation in this code.
It is not passing 2 test cases.

hi @vkth https://www.geeksforgeeks.org/program-for-nth-fibonacci-number/ you can see the various implementations for finding the nth fibonacci number here. Let me know if your doubt persists.

I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.

On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.