It is showing run time and wrong answer

This is my code i have used python as big integer can be easily handelled by python

As i am new to python please let me know my mistake
Logic:Is same as discussed in hint video
Thank You

can you explain your approach and what is fib() calculating.
the Ans = (n-1)!/((r-1)! * (n-r)!) or (n-1)C(k-1)

fib() is calculating (n-r+1)…(n-1) and (k-1)! seprately and the ans is their division


I have fixed the bug, in python integer division is done by // and / this does fraction division. and i have changed to fib function to calculate factorials for simplicity.