2 test cases failed out of 8

please anyone correct me in my code.

@anujsharmabadboy you have taken 3 inputs n n1 then again n1 without any condition so in the case when n=1 your code will give wrong answer. take care of this condition and update your code accordingly.