My code is not getting accepted inspite of giving correct answers in sample cases?

@mayank10 answer can exceed 64 bit limit so you can’t store it in long long int too, you have to use bigint() to store answer.