• Needs random tests

  • from my understing on playing around this is what happens:
    say you have a num = 1234

    if you make a new string variable like this

    var string = '' + num

    then the empty quotes defines the type as a string and then adds thew number to it which is automatically converted to a string

    so string == '1234' not 1234

  • Is this some sort of implicit conversion then? I played about with it in the console and can recreate the coversion but I don't understand how it works...?

  • What about correcting your kata issue instead of solving a new one;-)? Isn't it the first task of an author?

  • Hi, can't see the new testcases, because cw doesn't update this code before i solved the kata (so my changed testcases work as before). What i can see is the error of your "submit testcases" as before. The following message appears, which is not an error produced by my code (returning an empty list displays same error, with hint of missing bracket):
    Test Results:
    [eval]:33
    Test.assertSimilar(caesarPyramid("b difflz buufnqu up njnjd dbftbs pof uipvtboe"), 1, 1000, "This is not one of Caesar's commissioned pyramids"]);;
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    SyntaxError: missing ) after argument list
    at Object.exports.runInThisContext (vm.js:53:16)
    at Object. ([eval]-wrapper:6:22)
    at
    at node.js:328:29
    at _combinedTickCallback (internal/process/next_tick.js:67:7)
    at process._tickCallback (internal/process/next_tick.js:98:9)

  • Thank you for the feedback, I think I have resolved some of the issues you raised, except the no function name, I was unsure what you meant by this? PLease let me know what you think.

  • Normally i should mark different issues here;-)...
    Static tests are wrong - for example no function name, switched letters in one case "hundedr", generally wrong tests (use Test.assertSimilar instead of Test.assertEquals). Submit tests don't work too because of code errors...
    So nice idea of these combined and different tasks inside one kata, but at the moment bad implementation - sorry:-(...

  • I agree with that. A few random tests would be better to test if the solutions actually work

  • Thank you for your feedback, I will include that in the description.

  • Hi, you should specify some preconditions. Based on the tests:

    1. The list of cycles contains more than one unique integer bigger than 0.
    2. The result has to be floored.

    Regards,

    suic

  • Needs random testcases

  • I run the code and all the test cases pass, however, upon submission I recieve this error message: 'Value is not what was expected', any suggestions?

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