Ad
  • Custom User Avatar

    where did exactly 11 come from in this part?
    arr = [17, 12, 5, 6, 13, 3] where length is 6.
    solution says:
    this would return 7 due to
    (170 + 52 + 134 + 35) / 11 = 7.
    what is 11? shouldn't it be (170 + 52 + 134 + 35) / 4?
    arr length is 6, primes length is 4, the only match i found is
    5 + 4 + 2 + 0 = 11 (indexes)

  • Custom User Avatar

    I'm afraid novel ideas concerning primes are hard to come up with. There are already numerous similar kata's on codewars, hence it's a duplicate.