Ad
  • Custom User Avatar

    Missing a test assert.deepEqual( getDividers([127],[7]), [ 1, 127, 16129, 2048383, 260144641, 33038369407, 4195872914689, 532875860165503 ] );.

    It's not often I propose performance tests, but allowing solutions to find factors by enumerating up to the given number that is passed in prefactored is ridiculous. ( And people vote it Best Practice, and that just galls me. )

  • Custom User Avatar

    ( JS )

    Random tests are vulnerable to input modification

  • Custom User Avatar

    The list will always be in ascending order,

    In random test there are unsorted lists, lists with duplicates, ...

    A random sorted list without duplicates can be generated with

    from random import randrange, sample
    
    def random_hours_list():
        length = randrange(2, 24)
        return sorted(sample(range(24), k=length))
    
  • Custom User Avatar

    Re-raising the issue below: please don't resolve duplicate kata issues unless you can demonstrate that your kata has an actual substantial part that is different from that duplicated kata.

    Duplicate katas should be unpublished (or else someone will retire it manually anyway), according to kata rules they should not exist.