Ad
  • Custom User Avatar

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

  • Custom User Avatar

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

  • Custom User Avatar

    There is more than one thing wrong with your code. Most of them should be pretty clear when going through the code in a debugger, step by step. Did you try to inspect your code in your local IDE?

  • Custom User Avatar

    You need a better algorithm than what you have now. Counting all factors is a very bad approach, and, on top of that, your implementation of counting all factors is very, very slow.Switching between loops and lists and comprehensions and generators is not going to help if you stick to your current algorithm.

  • Custom User Avatar

    Generally speaking, this is about code efficiency. There may remain something about how you optomize that has not yet occurred to you.