Ad
  • Custom User Avatar

    You have to multiply two numbers to get to the target product, but you're only adding one of them to your list ;-)

  • Default User Avatar

    I don't get it, which part do you mean?

  • Custom User Avatar

    Every time you find a divisor you're throwing away the other part of the information ;-)

  • Default User Avatar

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

  • Default User Avatar

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

  • Default User Avatar

    Okay, thanks a lot :)

  • Custom User Avatar

    You're using a global var there, it holds the previous value when your function is called several times in a row.

  • Custom User Avatar

    Why result belongs to the class? The next time your function is called it'll have the previous value, that's why you get expected: 0 but was: 3. Not a kata issue, it's your code that should be fixed. Try calling your function several times in eclipse too, it'll also fail there.

  • Default User Avatar

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

  • Custom User Avatar

    The assertion with 39 is this one: assertEquals(3, Persist.persistence(39)); and it's ok. I've solved it in java and it worked fine for me.

  • Default User Avatar

    I've got a problem in Java. With 39 it says: "expected: 0 but was: 3", while 3 is the correct answer not 0...But it doesn't pass the other tests either.

  • Custom User Avatar

    I'm trying it with recursion as well.

    I calculate the value of the multiples and re-passing if it's not the expected. But, somehow it's not returning values after the recursion.