Sample tests use the old Codewars Python testing framework that isn't supported anymore
All random tests are huge and impossible to debug when there is a failed assertion
Assertions do not take into account any possible floating point errors, essentially restricting the solution space to one particular function in Numpy and rejecting all other (possibly) valid approaches
You definitely need to improve the instructions for this kata. Even now, I have no idea how this worked ---> pattern(30, 7) = [-1, -8, -3, -2, -1]. It would be helpful if you made the example better by showing why the output of [-1, -8, -3, -2, -1] makes sense coming from (30, 7).
python new test framework is required. updated in this fork
Bit of an inconsistency: instructions state you it should return an array of arrays, but the test (and attempt) cases expect a list of lists.
(EDIT by @kazk: Updated for Codewars framework)
Consider using numpy testing once this is deployed. This gives beautified and helpful output for test failures:
Why is the list split in 2? Just to do the same thing twice?
Also, why the hell was this approved? This is a duplicate.
You definitely need to improve the instructions for this kata. Even now, I have no idea how this worked ---> pattern(30, 7) = [-1, -8, -3, -2, -1]. It would be helpful if you made the example better by showing why the output of [-1, -8, -3, -2, -1] makes sense coming from (30, 7).