THIS IS MY SOLUTION

To the PROBLEM/QUESTION

Please help me identify the problem, because all the test cases I put, give the correct output, but it is not the correct answer! I am really confused…

Your solution is giving wrong answer for 1-digit numbers.

For example if n=2,

Answer given by your solution : 2

Correct answer : 4