There already are kata about sorting lists, and about grouping lists. If you really want links to originals, I can find 'em. ( I have a groupBy kata myself .. )
Spare us the input validation. See Docs -> Authoring -> Guidelines -> Kata Authoring Guidelines -> Task and Requirements -> Keep kata focused on one task. "Do one thing, and do it well."
Possibly spare us the splitting the string as well, because the function name indicates you are interested in sorting and grouping arrays with generic elements. Strings as encodings are suspicious and overrated. Use appropriate datatypes!
There already are kata about sorting lists, and about grouping lists. If you really want links to originals, I can find 'em. ( I have a
groupBy
kata myself .. )Duplicate.
Spare us the input validation. See Docs -> Authoring -> Guidelines -> Kata Authoring Guidelines -> Task and Requirements -> Keep kata focused on one task. "Do one thing, and do it well."
Possibly spare us the splitting the string as well, because the function name indicates you are interested in sorting and grouping arrays with generic elements. Strings as encodings are suspicious and overrated. Use appropriate datatypes!
This comment is hidden because it contains spoiler information about the solution