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.
Underscore is just a convention, "k for k,g in groupby(iterable)" also works perfectly.
kek
This comment is hidden because it contains spoiler information about the solution
You're confusing the output of two different tests, not a kata issue.
I have a really weird problem with this. I am using javascript as language everything is going good. But whenever I try to return my result it's breaking my function. console.log() works how I want it but when I switch it to the return at the end it's breaking the loops and duplicate mess up with my result.
Example
console.log(result.join('')) // prints: (((
return result.join('') //prints: ((((((
Also tried:
console.log(result.join(''))> return (result.join('')) // which means I just deleted console.log() and write return. with parentheses included and without them. can anyone help me
First I tried counting using a dictionary and using replace based on K,V pairs.
and second I tried using replacing iterating over the word
Both of these methods were unsuccessful.
I think for some reason it really really did not like using replace based on count values. I just couldnt get it to work in the end.
I ended up giving up and saw most everyone using newstring += ')', which I was going to do but I was too stubborn because I wanted to use the K,V in dictionary. I think I overthought this one :(
This comment is hidden because it contains spoiler information about the solution
This comment is hidden because it contains spoiler information about the solution
ah, the true answer
This one was a little bit frusterating. Eventually got it