Ad
  • Custom User Avatar
    1) test random tests (TestFindTheDivisors)
         test/solution_test.exs:21
         Assertion with == failed
         code:  assert divisors(n) == check_divisors(n)
         left:  [1, 2]
         right: [2, 1]
         stacktrace:
           (elixir 1.15.7) lib/enum.ex:989: anonymous fn/3 in Enum.each/2
           (elixir 1.15.7) lib/enum.ex:4379: Enum.reduce_range/5
           (elixir 1.15.7) lib/enum.ex:2514: Enum.each/2
           test/solution_test.exs:22: (test)
    

    There is a problem with one assertion in the Elixir version.
    The exercise requires to return a sorted list, but it fails when it gets [1, 2] it is supposed to expect [2, 1]