Loading collection data...
Collections are a way for you to organize kata so that you can create your own training routines. Every collection you create is public and automatically sharable with other warriors. After you have added a few kata to a collection you and others can train on the kata contained within the collection.
Get started now by creating a new collection.
To amplify the previous report in re the random tests expect the input as the result...
Try this:
public … {
return array;
}
When you Attempt, it will pass the Random tests, and it shouldn’t.
srfoster’s solution should work, but they had to do a workaround to get past the bug.
Also, the problem wording is ambiguous (politically correct for “it sucks”). The actual solution does not match the scenario - the solution sucks up much more space.
Better wording which matches the solution:
“Write a function that takes a String array and returns a String array in which each element is the contatenation of all preceding elements plus the current element.”
Wording which matches the scenario:
“Write a function that concatenates the elements of a String array.”
Then overhaul the solution and make it 8 kyu.