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.
How does this work, the kata clearly has a limit on the number of letters per lines and number of lines...
This happens because the curried function doesnt return a primitive value.
Yeah i guess lowest assesment of 5kyu for this kata was pretty accurate
I believe term is another thing all together. A polynomial consists of terms seperated by mathematical operators. I guess expreession could be a better word.
Actually not as arr.slice() methods 2nd argument is not inclusive, so for each of the arr.slice(i,j) the array is sliced from index i to j-1, thats why there's no error thrown
Just regular flags and loops at work, without any fancy array manipulations. Great work!!!
Elegant Solution
This comment is hidden because it contains spoiler information about the solution
This is quite similar to donaldsebleung's solution, but not as cryptic...
Short, concise and elegant.
Real clever :) But its gonna work only for those two inputs
Since I dont yet know regex yet that well this solution was the better one, albeit a bit verbose.
The actual documentation specified by the language would be the safest bet
An Elegant solution without using any extenal API's.