Ad
  • Custom User Avatar

    This comment is hidden because it contains spoiler information about the solution

  • Custom User Avatar

    This comment is hidden because it contains spoiler information about the solution

  • Custom User Avatar

    Could you provide some explenation on how does it work?

  • Custom User Avatar

    I've implemented it myself and I still think it is a 6 kyu due to it being a very basic task. If you still strugling with permutations, you might find this helpful

    https://www.youtube.com/watch?v=jUM_Dpt6yu0

    The video gives an insight on how the algorithm works and the best part -- it is 19 minutes long and you can stop at any momemt if you seem to catch the idea.

  • Custom User Avatar

    @Kacarott, thank you for your response! I will familiarize myself with material, also thanks for sharing that kata!

  • Custom User Avatar

    Well, I've studied lambda-calculus during me first term at the university and that almost left no mark in my memory or my brain but I saw kinda the beaty of Haskell even tho that never got far. This Kata shurely inspired me to dive into it and since you seem to be good at it, may I ask you to advise a classical book on lambda calculus?

  • Custom User Avatar

    I wrote that as a joke ofc and one should always validate data, especially if it is written in Kata's description;) It's like, in this Kata it's so obvious compared to the solution itself that it doesn't feel like necessary part of.

  • Custom User Avatar

    Great kata! But what kind of special agent would try to transmit an incorrect message or deck? Got me, otherwise I would pass on my first attempt... Anyways, I've really enjoeyd it!

  • Custom User Avatar

    UPD: on my next atempt I got [37, 37, 7] as expected value, so, clearly we allow multiple occurances.

  • Custom User Avatar

    Do we allow one number occur multiple times (like in first example in the description: [59, 3, 2, 2, 2])? Because, if so, then for n = 37500, command = min: [[25, 15, 10, 10], 240] is less than expected [[25, 20, 15, 5], 260]. If this is not allowed, then example in the description should be changed.

  • Custom User Avatar

    How is this 4 kyu? It's a bit annoying, but nothing hard. Should have been 5 or 6 kyu IMHO.

  • Custom User Avatar

    Hi! Good kata, but python tests are too small. My algorithm passed all tests in 7.61ms. Probably, it is still enough to sieve out 'naive-iteration solutions', but shouldn't be enough to pass only by using staight solution (didn't test tho).
    Afterall, nice kata!!!

  • Custom User Avatar

    Cool Kata!!! Would be greatfull, if someone provided tests with nested loops)

  • Custom User Avatar

    This comment is hidden because it contains spoiler information about the solution

  • Custom User Avatar

    Well, i didn't know of existance of such function, but I examined through the solutions and did not find something similat to what I have done. What is notable about about this solutions (inho ofc) is that ut is recursive algorithm, working exactly according to the definition given in ths kata. Ofc the standart solution is much better, but you, probably, see it only when you already know abot this function. Great kata anyway!

  • Loading more items...