• It took me some time to understand that given nested list should not be modified in the process. I think a clear mentioning of such requirement should be provided in the task section.

  • What is the purpose of the last line return?

  • This is no longer needed for python 3

  • Maybe just start with simpler kata?
    Not an issue, in any case.

    cheers

  • i don´t really know how to start please help

  • Exactly what I wanted to say! How this code pass the tests??
    Another remark : the while self.progree >=100... !!?? modulo and integer division do the job!?

  • Basically means you messed with the inputs somehow in your function and it wasn't the same as before. Try avoiding it by copying or something

  • I don't understand this error message
    input should not be changed: [[5, 2, [0, 0, 0, 0], [0, 0, 0, 0]], 1] should equal [[5, 2, [], []], 1]
    Does this message mean that [[5, 2, [], []], 1] should be a hypercube? it's strange...

    My code passes all tests except "input should not be changed" tests.

  • Am I misunderstanding this? The pattern looks like "If you see a lone number available in a slot, duplicate it appropriately, but if there is nothing there, add 0s", yet somehow your algo wants 3s here.

    don;t add zeros, add provided growing_value (which is 3 in this case)

  • Test case with given array [[], [], [], []] returns the following error:

    [[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]] should equal [[3, 3, 3, 3], [3, 3, 3, 3], [3, 3, 3, 3], [3, 3, 3, 3]]
    

    Am I misunderstanding this? The pattern looks like "If you see a lone number available in a slot, duplicate it appropriately, but if there is nothing there, add 0s", yet somehow your algo wants 3s here.

  • updated

    please look again

  • I like your handling with 0 ranks. Brilliant.

  • Your kata is really interesting, but presents A LOT of problems, for now...:

    Description / solution setup:

    • the optionnal parameter is incorrectly described/named: at first I understood it as something to add to the actual dimension of the nested lists while it's actually only a default value. So name it that way: default (well, it's said in the description, yes, but since there are no sample tests with that, the information is only shown "with 5 words" in the whole (huge) descirption)
    • not sure the hints are useful. Maybe just keep the one about recursion?
    • some typo in there (aN function somewhere near the end, for example)
    • just after the first code block, you have two definitions on the same line (lacking some formatting)
    • no need to put "nested list" in bold everywhere, especially when that's actually not what's important in the sentence ;) (see the definitions of size and dimension!)
    • you should put a short description of the task before you explain what a hypercube list is (not explainning all the details of the parameters at this moment, but just that You'll have to transform an input nested list into an hypercube list, which is a special kind of nested list where each level must have the very same size, the nesting going to the same depth in each branch too (You'll surely need to reformulate the last part about the depth: I cannot find a way to translate correctly what I have in mind in english). And only then give the example and the formal definitions if you want.

    Sample tests: you HAVE to put in there:

    • ALL the examples of the description (especially the most complex/first one!)
    • calls with the second parameter
    • tests with the dimension defined by a sublist (currently, it's always the first level that imposed the dimension)
    • same as above but feeding the function with a default value

    Test cases:

    • your random generator seems to be somewhat "unbounded". That means it sometimes generate very HUGE nested lists and/or that your generator sometimes fails to break out from a while loop or a recursion. And that means the test suite can sometimes badly time out for no apparent reason from the user's point of view.

    If you resolve all of these problems, your kata will become a really solid one. You put a lot of effort in the test suite, already, it's a good one. Just make it perfect! ;)

  • Loading more items...