Ad
  • Custom User Avatar

    Gotta say, I like how the test cases in this one heavily discouraged an iterative solution - pretty neat!

  • Custom User Avatar

    Slightly Clearer Description

    Task

    You are given an array of string inputs strarr and an integer k.

    Your task is to return the longest possible string that can be derived by combining k consecutive elements of the input strarr.

    Example

    longest_consec(["red", "orange", "yellow", "green", "blue", "indigo", "violet"], 2) should return "orangeyellow"

    Notes

    In the case of there being multiple possible matches, only the first one will be considered correct.

    In any of the following cases, the return value should be an empty string "":

    • strarr.length === 0
    • strarr.length < k
    • k <= 0
  • Custom User Avatar

    The kata calls for a 'strictly increasing' sequence, where each value is distinctly greater than that which came before.

    Since 1 is not greater than 1, your solution is not valid in the context of the kata.

  • Custom User Avatar

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

  • Custom User Avatar

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

  • Custom User Avatar

    Attempting to 'expand X replies' causes the message to disappear entirely instead of showing the replies.

  • Custom User Avatar

    Minor gripe: I feel testing over a 1,000 value array isn't adding much other than an excessive execution time to the kata. Especially since efficiency testing isn't part of the kata.

  • Custom User Avatar

    When viewing solutions for kata that I've completed, would it be possible to place my own solution at the top of the view?

  • Custom User Avatar

    I wonder if it might be better to have to complete a certain percentage of existing kata at a specific kyu rating before being allowed to progress upwards. As I understand the system currently, it takes 10 kata of equal rank to your own to progress, which makes it trivial to advance through the first couple of ranks due to sheer variety and difficulty variances in existing kata at lower ranks.

  • Default User Avatar

    What purpose would that serve, though?

  • Default User Avatar

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

  • Default User Avatar

    I learned something today because of this kata. Simpler than I thought it would be!

  • Default User Avatar

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

  • Default User Avatar

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

  • Default User Avatar

    Would help to explain that rooks can only move in straight lines horizontally or vertically in the kata description. Otherwise I have no objections.

  • Loading more items...