Ad
  • Custom User Avatar

    The timed out error occurs because the code has an infinite loop. The line n = n//2 is outside the while loop, so it never gets executed. This means the value of n never changes inside the loop, causing the loop to run indefinitely.

  • Default User Avatar

    This comment is hidden because it contains spoiler information about the solution