Ad
  • Default User Avatar

    Alright thank you, this helps me alot.

  • Custom User Avatar

    returns in your code are not structured correctly, and this causes a couple of problems:

    • post-iteration statement c++ in your inner loop is never reached, because your inner loop always hits break or return on the first iteration. Your inner loop never has a chance to execute more than once.
    • more serious problem though is that return can be completely missed if sentence would happen to be empty. Your inner loop will never enter, and return won't be encountered by the control flow. Compiler does not like this, you have to have some return statement which will be executed even if your for loops won't be entered.
  • Default User Avatar

    Well, I don´t really see where the problem lies, can someone give me a hint? After 2 weeks I still don´t know whats the problem. Is there a mistake in the logic or did I forget to call something or whatever, Im still new to this page so I wouldnt know.

  • Custom User Avatar

    After seeing your code, it's not a kata issue, it is a problem with your code.

  • Default User Avatar

    Oh alright thank you

  • Default User Avatar

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

  • Custom User Avatar

    Read this: https://github.com/codewars/codewars.com/wiki/Troubleshooting-your-solution

    Given it's one of your firsts katas and

    C# Completions 2646

    It's probably you who is doing something wrong. Don't open an issue in cases like this, use question label and provide your code using markdown formatting and marking your post as having spoiler content, otherwise there is no way to help you.

  • Default User Avatar

    There is an error appearing saying that the code is unreachable eventhough there is nothing wrong with the code. It can´t reach the for-loop which doesn´t make any sense since the code works on a different compiler.

  • Custom User Avatar

    A problem with your code is not a kata issue, read this: https://github.com/codewars/codewars.com/wiki/Troubleshooting-your-solution about how to debug your code and if you need help, how to ask for it properly, without your code we can't know what you did wrong.

  • Default User Avatar

    My code passed all the test cases but for the last one, it is throwing a Stack trace error. Could someone please help me figure out the issue?