Ad
  • Custom User Avatar

    If that was the case I think b/c I did Regex.Split(@"\s+"), which is unneccessary since white space is just a char other than ,.<>.
    I regret so much.. Thanks for letting me know! ;)

  • Custom User Avatar

    I paid for the Codewars Red subscription since I like the service. One of the pages there showed execution time, but I'm not sure where else you can view it. I believe it is visible immediately after submitting your solution though.

  • Custom User Avatar

    Where can we see the execution time?

    1. In the original problem, it calls Decrypt multiple times.
    2. For 3, if you filter with Regex, you don't need to do search.
  • Custom User Avatar

    Thanks for the compliment. A couple thoughts in response:

    1. Perhaps I misunderstand your point, but I don't believe you are correct. The regions will be reversed only once per call to Decrypt, not based on the length of the text parameter.
    2. This was a choice of brevity and clarity over performance, although I believe any performance difference would be inconsequentional in real world scenarios, and especially so in the context of a kata.
    3. I'm not sure I understand what you mean here.

    Generally, unless performance is an actual bottleneck, I think micro-optimizations that increase the amount of code you need to comprehend do more harm than good.

    Not that it matters, but my code executed in 2123ms vs. 2488ms for yours, so they are in the same ballpark.

  • Custom User Avatar

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