this happens to me in python more often than I'd like to admit. my understand is that it normally means code needs optimizing cuz it's not fast enough yet. it sounds like codewars.com implements the processor time restriction in a way that has some variability due to server load - I'm guessing for practical reasons + realism - so code that's right on the edge of efficient enough may sometimes pass & sometimes fail
Valid point, I did not know JS and Go only used parenthesis.
I've added a note to the description on a C# fork: Note: In the JavaScript and Go version of this Kata, input will only contain opening and closing parenthesis and will not be an empty string.
Maybe specific languages should be metioned? Many solutions in JS and Go assume that if it's not ( then it's ) and now they are kind of invalid. But they just followed the description.
It's fiiiiiiiixed. The description is fixed, folks. There has never been a better time to be alive on this sweet, sweet, sweet, green planet of ours, Earth.
Something amazing's happening. For reals. I ain't joking here, this is not a drill. Everyone... if people keep telling you your best days are behind you, they are so so wrong, they cannot be more wrong.
a possibly more straightforward way would be
in the body of the loop, but +1 for documenting your approach
nah, just checking cheat solution! don't use it :D
heh, talk about a 'general purpose solution'...
Nice! I wondered if I'd see anybody else using defaultdict. Gotta love the collections module for cleaner looking faster running code
this happens to me in python more often than I'd like to admit. my understand is that it normally means code needs optimizing cuz it's not fast enough yet. it sounds like codewars.com implements the processor time restriction in a way that has some variability due to server load - I'm guessing for practical reasons + realism - so code that's right on the edge of efficient enough may sometimes pass & sometimes fail
username checks out.
;)
Awesome!
This comment is hidden because it contains spoiler information about the solution
it's quick on these test cases, but sure not going to win any codegolf this way
Valid point, I did not know JS and Go only used parenthesis.
I've added a note to the description on a C# fork:
Note: In the JavaScript and Go version of this Kata, input will only contain opening and closing parenthesis and will not be an empty string.
If approved, it'll overwrite the description:
Maybe specific languages should be metioned? Many solutions in JS and Go assume that if it's not
(
then it's)
and now they are kind of invalid. But they just followed the description.It's fiiiiiiiixed. The description is fixed, folks. There has never been a better time to be alive on this sweet, sweet, sweet, green planet of ours, Earth.
Something amazing's happening. For reals. I ain't joking here, this is not a drill. Everyone... if people keep telling you your best days are behind you, they are so so wrong, they cannot be more wrong.
The future is now, my friend.
Should be fine now.
Fixed.
Loading more items...