Ad
  • Custom User Avatar
    • @LaurentBouvier - You are mixing up n and m, in (2,1), there are 3 points on a line, and 2 more on the arc.
    • @sadegh-moayedizadeh - You are ignoring the 2 points on the edges of the diameter and arc (A and B)
  • Custom User Avatar

    Such an unbalanced kata:

    • performance criteria not mentioned in description
    • random tests immediately deal with huge numbers
    • in javascript, numbers go way beyond max safe integer, rendering most solutions incompatible with ref solution
  • Custom User Avatar

    Fun kata, thank you. Suggest to fix a couple of typos in the description: diametr -> diameter and quadrilaterlas -> quadrilaterals. Also combinations is not the best function name in Python because it clashes with itertools.combinations.

  • Custom User Avatar

    I have the same question .... We have the example combinations(2,1) -->(9,3)
    In this configuration, we have all the points in a line but one ==> I don't see a way to have a quadrilaterals which is not a triangle + one point on one of the side. I think we need to take the name quadrilaterals in an extend way...

  • Custom User Avatar

    i think that i concidered all the possible combinations:
    *for triangles:
    1.two points on arc and one point on diameter
    2.two points on diameter and one point on arc
    3.three points on arc
    *for quadrilaterals:
    1.two points on diameter and two points on arc
    2.one point on diameter and three points on arc
    3.four points on arc

    this passes eleven tests but no more. do i miss out anything?

  • Custom User Avatar

    Crystal Translation done, please check.

  • Custom User Avatar

    I did exactly as author

    Nope.

    It's pretty simple: I told you what to change so that:

    1. your translation is consistent about the requirements with the python version (the one I use as reference)
    2. it's adapted to ruby's specificities in cw' encvironment.

    Now it's up to you: either you update your translation (again, in a fork of the current translation), or it just won't be approved.

  • Custom User Avatar

    I did exactly as author , also please look to other katas' translations, you will see that not always translations should be the same (even for languages like C/C++ or Python/Ruby which are pretty similar). God bless u , dude

  • Custom User Avatar
    • test cases part, in the describe block: it's supposed to be a it block, not a functin definition (as you did for the sample tests)
    • in the functions simple_test and harder_test, the ranges must be inclusive on both limits, so that it's consistent with what's in the description.
    • about the description: did you update it for ruby (check the code blocks at the end. I don't have the info when looking at your translation here, since I see the rendered description, not the code generating it)
    • specificity of ruby (sort of): the ref solution should be declared in a closure when possible, with a less obvious name (otherwise it's accessible to the user). Along the same line, don't compute the expected value right in the assertion, but call the reference solution before (actually boils down to: "don't call the ref solution and the one of the user on the same line of code")
    • when looking at "view output", I see 500 assertions and the output is pretty weirdly formatted. I guess it's because of point 1. We'll see after the correction, so.

    Note: your current translation is rejected, meanig that this version cannot be approved. You have to fork it rather than edit it so that the fresh version can be approved.

    'later

  • Custom User Avatar

    I tried to make it exactly like in original test. Is it ok now?

  • Custom User Avatar

    And how is this a kata issue?? You can ask questions under any specific solution, if that helps. Closing...

    Edit: what the hell, sorry. It was showing up as issue to me. But you should use spoiler flag for questions like this.

  • Custom User Avatar

    You can search about fibonacci ladder problem where length of steps not greater than 2. Then think about generalization of this problem.

  • Custom User Avatar

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

  • Custom User Avatar

    pretty simple: unless there are preformances adpation needed, a translation in a new language must be fully equivalent to the previous ones. Yours was having only 2 single tests...

    Note that fixed tests have been added to the test suite too.

  • Custom User Avatar

    If you explain nicely , I will try to fix translation. Thanks in advance.

  • Loading more items...