• Hello.

    First of all, it would be nice to know what programming language you are using. Second, it would be a lot more helpful if you descripted what your code was doing wrong, rather than just paste your code into the chat. If you don't have to mark your message as spoiler, more people will be able to see it and help you.

    I assume that I know the answer your your issue though. It is a very common mistake that people do in this kata, not knowing the difference between sorting a list of numbers verse sorting a list of strings.
    You can see an example used to explain it here.

    The comment right underneath yours even asks the same question.

  • Your code returned "6 -214", but the test was expecting "542-214".

    It is a very common mistake people make in this kata. You now have to learn the difference between sorting a list of strings and sorting a list of numbers. Have fun!

    For more explanation, you can see this.

  • Aproved.

  • Looks good. Accepted.
    I might remove some of the Sample Test Cases later though.

  • When you click the "Test" button, it runs the "Sample Tests" code. You can write your own test code there.
    When you click the "Attempt" button, it runs the hidden tests which you need to pass in order to finish the Kata.

    The output window will show how your code did in each test, commonly in some format like "passed" or "Expected: 1 -1, but was: 1 0".
    The exact output depends on the programming language and how the tests are written, some might be easier to understand than others.
    In a some case people might be able to figure out what your mistake is simply by what the test error output is, which means you don't have to show your code and mark your post as spolier.

    When the "Attempt" test runs without error, the button will change to a green "Submit" button instead.

  • See the docs on information on how to use the site.

    And this is the comment section specific for the "Highest to Lowest" Kata, I don't think there is a global messaging section.

    You might want to mention which programming language you are using, as I think almost all programming languages have a Sort method, and your issue might be specifically related to which programming language you are using.
    If you can tell us what the output of the test is, it might be easier to see what your issue is. If that doesn't work you can share your code, just remember to mark your comment as "spoiler".

    I had assumed that the main things needed would be already be imported for us to solve the Katas.

    This definitelly depends on which programming language you are using. But for this Kata, no, the needed imports/usings are not always included. I think it would be too easy if it was, and I might be slightly evil.

  • Aprroved.

  • Looks good to me.

  • You can't. Hence the annoyance when people keep doing it.

  • Please don't post solutions in the Discourse section. That is what the Solutions section is for.
    If you want to submit another solution, you simply click "Train Again" and submit your new solution, it will then be added to the Solutions section.

  • Since all the number are separated by a single space, it should be easy to convert the string into an array/list, or you can just go through it char by char and make the array/list manually.

    I don't use JavaScript very often (and if I do I always wash my hands afterwards), so I don't know the exact options you have available or what other things you will have to do to the list afterwards. The easiest is likely just to google something like "JavaScript convert string to array" or something.

    I also don't want to spoile too much. Learning to google for answers and ideas is important nowadays.

  • As far as I know, no one has ever used RegEx in this kata challenge. I don't really see why anyone would.

    Any specific reason you ask?
    Which programming language are you using?

  • Very common mistake.
    I think i explained it nicely here.

  • Please don't post solutions in the Discourse section. If you want to show another solution, you can just try the kata again and it will be added to the Solutions section.

    PS: Your formatting could use a little work, add a codebox around the code in your comment.

  • You don't understand what? Programming in general? The Codewars site? This kata challenge?

    This discussion section is for this specific kata challenge. I don't know where you should ask for general Codewars help, but I doubt this is a good place to ask.

    The FAQ might anwer some questions, but it doesn't seem to cover the very basics of how to use the Codewars site.

  • Loading more items...